projects
/
mono.git
/ blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
history
|
raw
|
HEAD
make exvar_offset signed
[mono.git]
/
mono
/
tests
/
switch.cs
1
public class Switch {
2
3
public static int test (int n) {
4
switch (n) {
5
case 0: return 1;
6
case 1: return 0;
7
case -1: return 2;
8
default:
9
return 0xff;
10
}
11
return 100;
12
}
13
public static int Main () {
14
if (test(0) != 1)
15
return 1;
16
if (test(1) != 0)
17
return 2;
18
if (test(-1) != 2)
19
return 3;
20
if (test(3) != 0xff)
21
return 4;
22
return 0;
23
}
24
}
25
26