[Issue 12839] std.parallelism with nested functions and lambdas. Segfault

via Digitalmars-d-bugs digitalmars-d-bugs at puremagic.com
Tue May 12 05:26:17 PDT 2015


https://issues.dlang.org/show_bug.cgi?id=12839

--- Comment #5 from Maxim Fomin <maxim-fomin at outlook.com> ---
Now it gives ice. 

auto loo(int a)
{
    auto inner()
    {
        return a; // debugger caught SEGV at this line
    }

    return () => () => inner();
}

void main()
{
    assert(loo(3)()() == 3);
}

DMD v2.068-devel-df9b8af-dirty DEBUG
dmd: toir.c:183: elem* getEthis(Loc, IRState*, Dsymbol*): Assertion
`thisfd->isNested() || thisfd->vthis' failed.
Aborted

--


More information about the Digitalmars-d-bugs mailing list