projects
/
mono.git
/ blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
history
|
raw
|
HEAD
[xbuild] Add 14.0 toolchain
[mono.git]
/
mcs
/
tests
/
test-869.cs
1
using System;
2
3
public class C
4
{
5
public static readonly C Token = new C ();
6
7
public static C operator & (C set, E value)
8
{
9
return Token;
10
}
11
12
public static implicit operator E (C c)
13
{
14
throw new ApplicationException ();
15
}
16
}
17
18
public enum E
19
{
20
Item = 2
21
}
22
23
enum E2
24
{
25
A = 0,
26
B,
27
C
28
}
29
30
class FooClass
31
{
32
public static int Main ()
33
{
34
C m = new C ();
35
var x = E.Item;
36
var res = m & x;
37
if (res != C.Token)
38
return 1;
39
40
res = m & E.Item;
41
if (res != C.Token)
42
return 2;
43
44
E2 e2 = E2.C;
45
46
int day1 = e2 - E2.A;
47
return 0;
48
}
49
}