I\'ve always wondered this - why can\'t you declare variables after a case label in a switch statement? In C++ you can declare variables pretty much anywhere (and declaring
Try this:
switch (val) { case VAL: { int newVal = 42; } break; }