is struct delete deterministic? (cf used in Unique)

Timothee Cour via Digitalmars-d-learn digitalmars-d-learn at puremagic.com
Sat Mar 7 15:48:31 PST 2015


I'm a little confused about the following:
clear,delete,destroy.
My understanding is that clear is deprecated and delete is planned to be
deprecated, so we should only ever use destroy (which deterministic calls
the destructor but doesn't release memory).

Unique uses delete however in the destructor. Is that still guaranteeing
deterministic destruction when the uniqued element is either a class or
struct? (ie if the destructor has a file handle resource, will it be
deterministically freed?)
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.puremagic.com/pipermail/digitalmars-d-learn/attachments/20150307/64a2adbd/attachment.html>


More information about the Digitalmars-d-learn mailing list