Is there a way around this or a better way to accomplish what I'm trying to do? I just want a lightweight handle to a manually-allocated dynamic array that I can append to and stuff, and frees itself on destruction (so I can keep them in various containers and know that freeing will automatically happen when I remove it).
I have a Resource struct that is supposed to free some memory
when it gets destroyed. Unfortunately, I can't define a
destructor. If I do, the compiler complains that it can't destroy
the shared versions. If I define a shared destructor, the
compiler complains that it can't disambiguate between ~this() and
shared ~this().
- shared and nonshared dtor Vlad Levenfeld via Digitalmars-d-learn
- Re: shared and nonshared dto... Jonathan M Davis via Digitalmars-d-learn
- Re: shared and nonshared... Vlad Levenfeld via Digitalmars-d-learn