Hello fellow coders,
Version 0.2 of the packarray class is available at the same spot:
http://www.netdirect.ca/~cdfrey/software/packarray.cc
This version handles endian issues all at once, and converts double
values to network byte order as well. The basic_field<> class is gone,
as it's not needed any longer.
I ran into an interesting issue with regards to C++ aliasing rules, which
you can read about here:
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=25235
And here:
http://mail-index.netbsd.org/tech-kern/2003/08/11/0001.html
This makes me rather concerned about the reinterpret_cast<> I have to do
in 4 places in packarray. Any tips on how to clean that up would be very
much appreciated.
Anyway, it works great for me, even with g++ 4.0.2. Testing on non-intel
machines would be great.
Enjoy,
- Chris