On 10/31/2010 10:42, Andrei Alexandrescu wrote: > There are several solutions possible, some that require the compiler > knowing about the idiom, and some relying on trusted code. One in the > latter category is to create immutable objects with an unattainable > reference count (e.g. size_t.max) and then incrementing the reference > count only if it's not equal to that value. That adds one more test for > code that copies const object, but I think it's acceptable.
This means that immutable objects do not have deterministic destructors. I don't think this is acceptable. -- Rainer Deyke - rain...@eldwood.com