sclytrack:

Why not just go manual memory. Just store everything
in a tree-like structure.

SuperOwner
--Child1
--Child2
----SubChild1
----SubChild2
------Container1
------Container2
------TStringList

Freeing a Child2 disposes of everything below.

Something like this?
http://swapped.cc/?_escaped_fragment_=/halloc#!/halloc

A manual hierarchical allocator is possibly handy to have in Phobos. But it doesn't replace a owning scheme for automatic memory management.

Bye,
bearophile

Reply via email to