https://issues.dlang.org/show_bug.cgi?id=17641
[email protected] changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |[email protected] --- Comment #1 from [email protected] --- (In reply to andronkin from comment #0) > auto d1 = delegate void(uint a) { writeln(a); }; > auto d2 = delegate void(uint a) {}; > > assert(typeid(d1) is typeid(d2)); // FAILED! Although type hasn't been > changed... The type of d1 has changed. Try printing them with `pragma(msg, ...)`: ---- pragma(msg, typeof(d1)); pragma(msg, typeof(d2)); ---- Prints: ---- void delegate(uint a) @safe void delegate(uint a) pure nothrow @nogc @safe ---- You see that d1 is not `pure nothrow @nogc`. Because `writeln` isn't. > Also, the string representation of typeid(d1) is "void delegate()", although > there must be a "void delegate(uint)". Yeah, that looks wrong. --
