Help with reading and writing to a file
Steve Torri
storri at torri.org
Fri Jun 11 18:37:11 CEST 2004
On Fri, Jun 11, 2004 at 06:16:38PM +0200, Michel Bardiaux wrote:
> If you had posted the *dump* you would have looked at it and seen that
> there is nothing between the 2 strings. So, when you read back in, the
> runtime follows the normal rules: when reading a number, it stops when
> it sees a non-digit. There are 8 consecutive digits so of course they
> are read in as *one* number. You get zero for the 2nd one, you should
> have checked for EOF.
>
> My C++ is basic at best but I thing what you need is:
>
> m_file_handle << val << ""
>
How does one post a "dump"? Our definition of words I think may be
different.
In regards to the line you gave it does not work. I will provide a
better answer in the way you want (e.g. a dump of the binary file)
when I receive your answer to my question.
Stephen
More information about the gmp-discuss
mailing list