$ cat bug.d class Statement: Node{} class Declaration: Statement{} class Node{ mixin Foo!Declaration; } template Foo(T){ mixin(T.stringof~" x;"); } $ dmd bug.d # DMD 2.070.0 bug.d(2): Error: class expression.Declaration is forward referenced when looking for 'stringof' bug.d(3): Error: mixin expression.Node.Foo!(Declaration) error instantiating
Works with DMD 2.060.
Regression has been introduced in 2.066.
https://github.com/D-Programming-Language/dmd/pull/5516
Commits pushed to stable at https://github.com/D-Programming-Language/dmd https://github.com/D-Programming-Language/dmd/commit/f6426fe7c7b8addb96d4f1b72b9d03653187d6ce fix Issue 15733 - Forward reference issue involving inheritance https://github.com/D-Programming-Language/dmd/commit/5264c960defa38772a6939eba039390729a26ab6 Merge pull request #5516 from 9rnsr/fix15733 [REG2.066] Issue 15733 - Forward reference issue involving inheritance
Commits pushed to master at https://github.com/D-Programming-Language/dmd https://github.com/D-Programming-Language/dmd/commit/f6426fe7c7b8addb96d4f1b72b9d03653187d6ce fix Issue 15733 - Forward reference issue involving inheritance https://github.com/D-Programming-Language/dmd/commit/5264c960defa38772a6939eba039390729a26ab6 Merge pull request #5516 from 9rnsr/fix15733