Name: Anonymous 2011-10-16 22:47
If I do this with C#:
Visual studio gives me an error because some idiot decided that in C# it won't let you fall through to the next case label anymore.
But if I do this:
It gives me an error about redefining my variable, EVEN THOUGH YOU'VE FORCED ME TO MAKE EVERY "case" CLAUSE A COMPLETELY SEPARATE ENTITY.
switch(foo) {
case 0:
case 1:
}Visual studio gives me an error because some idiot decided that in C# it won't let you fall through to the next case label anymore.
But if I do this:
switch(foo) {
case 0:
int bar = 3;
break;
case 1:
int bar = 4;
break;
}It gives me an error about redefining my variable, EVEN THOUGH YOU'VE FORCED ME TO MAKE EVERY "case" CLAUSE A COMPLETELY SEPARATE ENTITY.