Boost logo

Boost Users :

From: Pfligersdorffer, Christian (Christian.Pfligersdorffer_at_[hidden])
Date: 2008-08-25 04:36:19


Hi everyone!

On 24 Aug 2008, at 21:39, Bo Peng wrote:

>> This was actually tested on various platforms of different 32/64
>> endian combinations. And the test consisted of running ALL
>> serialization tests as is done with the "official" archive
>> implementations. To me, the main problem is that its missing support

>> for floating point types.
>> Including such support in a definitive, portable manner would be a
>> significant effort which so far no one has deigned to undertake.
>
> Please forgive my ignorance, but what is 'floating point types'?
> QDataStream simply dump the internal presentation of float or double
> numbers and swap them for big small endian coding if necessary...

That's what I do too: using fp_utilities I dump the bit pattern and
restore it later on. This works for "almost all" environments. However,
the word "almost" is a problem for an ultraportable library such as
boost. Andrea Denzler already mentioned the difficulties: IEEE754 is not
universally, nan-representations and endianness differ and forget about
long double when talking about portability. Conclusion: the "definitive,
portable manner" Robert talks about will be very hard to achive. On the
other hand: supporting IEEE 754 types float and double is (almost) easy.
Let's be pragmatic about that!

Regards,

-- 
Christian Pfligersdorffer
Software Engineering
http://www.eos.info

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