Boost logo

Boost Users :

From: Ákos Maróy (akos_at_[hidden])
Date: 2008-08-08 06:59:53


dizzy wrote:
> On Friday 08 August 2008 13:08:57 Andrea Denzler wrote:
>> If you send a byte, a byte should arrive.
>> If you send a wchar_t it has a different size on different platforms.
>> If you send a integer it has different endianess (byte order).
>> Maybe this last point is your issue. You have the same problem with file
>> formats.

a possible solution could be to implement my own serializers for
integral types, that use the very same bitwise pattern? (endiannes,
size, etc.)

> I think he was expecting that binary_archive is already fixed/portable binary
> layout. Apparently not (that is news for me too).

yes, basically that was my expectation, that I serialize something.
store it, de-serialize it using the _same_ implementation, but maybe
compiled for a different platform, and then it would work fine.

> As for the other mentioned portable archive, I'm curious about integral
> encoding efficiency, Google's Protocol Buffers seem to be very efficient in
> that regard (both in bytes used for representation but also encoding/decoding
> operations speed)
> http://code.google.com/apis/protocolbuffers/docs/encoding.html

interesting. I'll take a look..

Akos


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