On Tuesday, 17 May 2016 at 14:22:51 UTC, Meta wrote:
On Tuesday, 17 May 2016 at 09:54:15 UTC, Marc Schütz wrote:
You surely mean "used to be destroy", right?

Good question... If I write this:

struct Test
{
    ~this() { writeln("destroying Test"); }
}

with (Test())
{
    //Do stuff
}

Will Test's destructor be run once we exit the `with` scope?

Yes, it was fixed almost two years ago:

https://github.com/dlang/dmd/pull/3855

Reply via email to