Boost logo

Boost Users :

From: Frank Birbacher (bloodymir.crap_at_[hidden])
Date: 2007-08-18 03:19:57


Hi!

Hector C. schrieb:
> Hi all,
>
> Can anyone give any ideas why uncommenting the #define
> will give me errors?

Right now I don't know. But here

> std::wofstream off("test.txt",
> std::ios_base::binary);
> boost::archive::binary_woarchive oa((std::wostream
> &)off);

and

> std::ofstream off("test.txt", std::ios::binary);
> boost::archive::binary_oarchive oa((std::ostream
> &)off);

here you are casting unnecessarily. Also do not use these kind of casts.
Try using "static_cast<Targettype>(what-to-cast)". If that fails think
about what you are doing.

Frank


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