
23 Oct
2009
23 Oct
'09
9:47 p.m.
Ben wrote:
{ std::ifstream ifs(fname); boost::archive::binary_iarchive ar(ifs); ar >> static_cast<A*>(a2p); }
You're trying to write to an rvalue. Note that int *ip = 0; static_cast<int*>(ip) = 0; // lvalue required as // left operand of assignment doesn't compile either... -t