2009/5/12 Arthur Schwarz: > > Program and particulars below. > > When line 27 is commented out, line 26 is output. When line 27 is not > commented, line 26 is not output except that if x.file contains a line feed > the null line line 26 & line 27 are output. If x.file does not contain a line > feed, only line 27 is output. > > Does the line feed have an effect on the 'cout <<' of line 26 of the program? > > Note. The code is awful and this is an example.
Hi Arthur, This question is off-topic on this list as it has nothing to do with development of gcc, the gcc-help list or a C++ forum would be better. I would guess that your file has DOS-style line-endings so a carriage-return is output after line 26, and line 27 is overwriting the output of line 26. Jonathan