From -7815158779834053237
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: f78e5,f330f27bea8a80d1,start
X-Google-Attributes: gidf78e5,public
X-Google-ArrivalTime: 1994-10-11 03:47:20 PST
Newsgroups: comp.std.c++
Path: bga.com!news.sprintlink.net!howland.reston.ans.net!pipex!uunet!hearst.acc.Virginia.EDU!maxwell!gcl8a
From: gcl8a@Virginia.EDU (Gregory Carl Lewin)
Subject: File input problem
Message-ID: <CxH771.Czy@Virginia.EDU>
Organization: University of Virginia
Date: Mon, 10 Oct 1994 21:18:37 GMT
Lines: 23

I have encountered a mysterious problem while inputting files
with a while{} loop.  In particular, when I use the following
statements:

	while(inFile)
		{
		inFile.get(ch);
		cout<<ch;
		}

the while loop seems to cycle one extra time, adding a spoace
to the end of the line.  This happens in TC++ 3.1, BC++4.0
(EasyWin and WinApp(with out the cout, of course)).

Is there a fix for this?

Please respond via email to:
gcl8a@virginia.edu

Thank you,

Greg Lewin
.


