Walter Bright wrote:
Something for everyone here.
http://www.digitalmars.com/d/1.0/changelog.html
http://ftp.digitalmars.com/dmd.1.046.zip
http://www.digitalmars.com/d/2.0/changelog.html
http://ftp.digitalmars.com/dmd.2.031.zip
Why is 'final switch' required? Another possible way of dealing with the
same issue would be:
switch(e) {
case E.A: blah; break;
case E.B: blah; break;
...
default: assert(0);
}
Ie, if switch is over an enum type, and the 'default' clause consists
only of assert(0), the compiler could generate a warning if some of the
possible enum values never appear in a case statement.
It's not quite the same as 'final switch', but I think it captures most
of the use cases.