projects
/
mono.git
/ blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
history
|
raw
|
HEAD
2004-06-08 Zoltan Varga <vargaz@freemail.hu>
[mono.git]
/
mono
/
tests
/
enumcast.cs
1
namespace Test {
2
enum MyEnum {
3
ZERO,
4
ONE
5
}
6
public class Test {
7
8
static int unbox_and_return (object obj) {
9
return (int)(MyEnum)obj;
10
}
11
public static int Main() {
12
if (unbox_and_return (MyEnum.ZERO) != 0)
13
return 1;
14
if (unbox_and_return (MyEnum.ONE) != 1)
15
return 2;
16
return 0;
17
}
18
}
19
}