[Issue 14894] mangling of mixins and lambdas is not unique and depends on compilation flags

via Digitalmars-d-bugs digitalmars-d-bugs at puremagic.com
Wed Jun 14 14:34:20 PDT 2017


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

--- Comment #11 from uplink.coder at googlemail.com ---
(In reply to Martin Nowak from comment #10)
> (In reply to uplink.coder from comment #9)
> > The way I see forward is to not use a number.
> > But to disambiguate by a reproducible hash.
> 
> Yes! What to hash though? Source code, tokens, parsed AST? Guess the latter
> would remain identical even after reformatting which is a nice property (but
> not an important one).

We need AST-Node hashing anyhow.
but that won't fix the .di files problem, as the hash will be different from
the impl.... or does the source have to be available ?
If it does then we stand a chance.

This will also auto-magically de-duplicate lambdas with the same bodys.

--


More information about the Digitalmars-d-bugs mailing list