GC has a "barbaric" destroyng model, I think

Mike Parker via Digitalmars-d-learn digitalmars-d-learn at puremagic.com
Thu Feb 12 02:24:43 PST 2015


On 2/12/2015 6:09 PM, weaselcat wrote:
> On Thursday, 12 February 2015 at 08:33:35 UTC, Kagamin wrote:
>> Truth be told, D has no guideline for deterministic destruction of
>> managed resources.
>
> +1
>
> don't complain about people wondering why class destructors don't work
> when there's no _real_ way to do it in D beyond 'drop down to C level
> and get going.' D is absolutely horrid for resource management.

I'm not complaining. I'm simply suggesting that the very word 
"destructor" likely plays a role in the misconception that class 
destructors behave as they do in C++. However, I do think that when 
moving from one language to another, there has to be a certain 
expectation that things are going to be different and it shouldn't be a 
surprise when they are.


More information about the Digitalmars-d-learn mailing list