Any reason as to why this isn't allowed?

Paul O'Neil via Digitalmars-d digitalmars-d at puremagic.com
Sat Apr 2 09:58:14 PDT 2016


On 04/02/2016 09:02 AM, Lass Safin wrote:
> class C {
>          ~this() {}
>          immutable ~this() {}
> }
>
> This gives a conflict error between the two destructors.

What do you expect the difference to be?  I'm not sure what I expect the 
semantics of destroying an immutable object to be.


More information about the Digitalmars-d mailing list