Article View: gnu.gcc.help
Article #52265using pruinf to rewrite over the same line with gcc (\r used to work)
From: Edward J. Hartnett
Date: Mon, 07 Dec 1992 15:51
Date: Mon, 07 Dec 1992 15:51
23 lines
1511 bytes
1511 bytes
Hi! I have the following line in one of my programs:
printf("%d soundings have been processed.\r",num_snd) ;
This used to be compuiled with the sun compiler, and it had the effect
of rewriting on top of itself so that only the number would change as
the program processed many many soundings. (BTW it only printed this
pout for every 1000 soundings, not every one).
Someone gave me this \r trick on comp.lang.c and warned me that it
might not be portable. I said that didn't matter. Well, I was wrong.
Now I've converted the program to ANSI and am using gcc, and this line
now does the following:
1000 soundings have been processed.
Can anyone help me find a way to do what I want in gcc? This is on a
Sun IPC runbning SunOS 4.1.1, with gcc version 2.3.1
Thanks.
--
Don't blame me, I voted against Amendment 2!
Edward Hartnett ejh@khonshu.colorado.edu
Technical Details
Message-ID:
<EJH.92Dec7155113@khonshu.colorado.edu>Path:
arc1-ca.pugleaf.net!sparky!uunet!stanford.edu!agate!boulder!colorado.edu!ejhShow Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 11318c,fad0086482dd1b5b,start X-Google-Attributes: gid11318c,public X-Google-ArrivalTime: 1992-12-07 15:21:25 PST Newsgroups: gnu.gcc.help Path: arc1-ca.pugleaf.net!sparky!uunet!stanford.edu!agate!boulder!colorado.edu!ejh From: ejh@khonshu.colorado.edu (Edward J. Hartnett) Subject: using pruinf to rewrite over the same line with gcc (\r used to work) Message-ID: <EJH.92Dec7155113@khonshu.colorado.edu> Sender: news@colorado.edu (The Daily Planet) Nntp-Posting-Host: khonshu.colorado.edu Organization: CIRES, University of Colorado Date: 7 Dec 92 15:51:13 Lines: 24