Topic: PB with ifstream and


Author: Michiel Salters<Michiel.Salters@cmg.nl>
Date: Tue, 23 Oct 2001 16:47:59 GMT
Raw View
In article <3BD51DD6.DB5B50C6@imag.fr>, Patrick Fourcade says...
>
>
>Hello,
>
>If I have a
>ifstream Input;
>(even protected)
>and at the end of text file some space characters,
>Input.eof does not jump to one and furthermore the adresse of Input jump
>
>to Null
>when the last command is : Input << Word.
>
>Is someone have had the same problem ?
>Thank you.

I don't think there is a problem here. ifstream::eof was not designed
to move the current read location ("jump").

regards,
Michiel Salters

--
Michiel Salters
Consultant Technical Software Engineering
CMG Trade, Transport & Industry
Michiel.Salters@cmg.nl

---
[ comp.std.c++ is moderated.  To submit articles, try just posting with ]
[ your news-reader.  If that fails, use mailto:std-c++@ncar.ucar.edu    ]
[              --- Please see the FAQ before posting. ---               ]
[ FAQ: http://www.research.att.com/~austern/csc/faq.html                ]