Boost logo

Boost Users :

From: Martin Ecker (martin.ecker_at_[hidden])
Date: 2005-07-10 15:39:11


Ivan Rachev wrote:
> If class A from the example is replaced by char, how should this
> situation be handled? Code follows at the end.

This is not recommended. Fundamental types are not tracked by default, so it
won't work. You'd have to turn on tracking for char, but that is not a good
idea, since then _all_ values of type char that are tracked, and this can cause
quite a bit of overhead.

If you really need a pointer that directly points into an array (and you can't
redesign the code), you could wrap the array elements in a different type that
can be tracked in your serialization code. All pointers into the array would
also need to be wrapped when serialized.


Boost-users list run by williamkempf at, kalb at, bjorn.karlsson at, gregod at, wekempf at