DMD 2.070 crash with the evil following construct: ----------------- import std.stdio; import std.typecons; import std.range; void main() { int id = 0; switch (id) { static immutable myArray = iota(100).array; foreach(i; myArray) { case i: writefln("i: %d", i); break; } default: ; } } ----------------- http://dpaste.dzfl.pl/4acbf36da8a4
This case is deprecated now, should this issue be closed then ?
Tested on latest git master (153db26c226d84a27a926810025b91eb6583849c), confirmed that this no longer crashes the compiler. Compiler output: ------ test.d(20): Deprecation: use { } for an empty statement, not ; test.d(15): Error: case variable i declared at test.d(13) cannot be declared in switch body ------