Boost logo

Boost Users :

From: Wang Yun (a_hao_at_[hidden])
Date: 2006-05-15 22:54:43


Robert Ramey wrote:

>>And I have another question, in the version 1.34's document(from cvs),
>>in the Pending issues, you say "Floating point values which are number
>>cannot be serialized to text base archives.".
>>
>>
>
>It should say "Floating point values which are NOT a number (Nan)
>cannot be serialized to text based archives.".
>
>
>
>>Is this means that if I
>>want to save same float or double value, I can only use
>>binary_archive?
>>
>>
>
>No it just means that you can't store the float that results from
>an undefined operation such as x/y where y == 0.0 . I would
>recommend that you using something like
>
>serialize(Archive &ar, version ..)
> assert(! is_nan(f));
> ar << f;
>}
>
>or something like that.
>
>Robert Ramey
>
>
>
I see, thanks.
Wang Yun


Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net