What am I doing wrong or is there a bug in the switch statement?
Code:
{ int $a = -5; switch($a) { case -5: print("$a was -5\n"); break; default: print("$a was some other number\n"); } }
Code:
// Error: case -5: // // Error: Line 6.11: Syntax error // // Error: default: // // Error: Line 9.12: Syntax error // // Error: }; // // Error: Line 12.1: Syntax error //
case (-5): doesn't work either...