singrdk/base/Windows/csic/test/switch1.cs

13 lines
253 B
C#
Raw Normal View History

2008-11-17 18:29:00 -05:00
class T {
public static void f(int x) {
switch (x) {
case 1: x = 1; goto case 4;
case -2: x = 2; break;
default: System.Console.WriteLine(x); break;
case 4: x = 5; goto default;
}
}
public static void Main() {
f(1);
}
}