blob: c49949b239ac575543d245d6b734788fd7c941be (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
|
class Test
{
static int test1 ()
{
var s = "Nice";
switch (s) {
case "HI":
const string x = "Nice";
return 1;
case x:
return 2;
}
return 3;
}
public const string xx = "Not";
static int test2 ()
{
var s = "Nice";
switch (s) {
case "HI":
const string xx = "Nice";
return 1;
case xx:
return 2;
}
return 3;
}
static int Main ()
{
if (test1 () != 2)
return 1;
if (test2 () != 2)
return 2;
return 0;
}
}
|