Boost logo

Boost :

From: Peter Dimov (pdimov_at_[hidden])
Date: 2004-11-11 14:31:04

Larry Evans wrote:
> If you could "reflect" all the reference counted smart_ptrs, like
> shared_ptr, for a class, T, into some class specific structure, say
> gc_desc<T>, then you could use this for precise garbage collection,
> AFAICT. Although it does expose the guts (after all, shared_ptr<X>,
> might be private in T), this is what you'd need to detect cycles.

sp_collector.cpp finds shared_ptr instances with a memory scan. That's not
the problem. The problem is following other owning pointers.

Or, in more general terms, the problem is that different reflection clients
need different things to be reflected.

Boost list run by bdawes at, gregod at, cpdaniel at, john at