projects
/
mono.git
/ blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
history
|
raw
|
HEAD
* expression.cs (Invocation.IsApplicable): Reorganize slightly to
[mono.git]
/
mcs
/
tests
/
test-123.cs
1
class X {
2
3
static object get_non_null ()
4
{
5
return new X ();
6
}
7
8
static object get_null ()
9
{
10
return null;
11
}
12
13
static int Main ()
14
{
15
int a = 5;
16
object o;
17
decimal d = 0M;
18
19
//
20
// compile time
21
//
22
if (!(get_non_null () is object))
23
return 1;
24
25
if (get_null () is object)
26
return 2;
27
28
if (!(a is object))
29
return 3;
30
31
//
32
// explicit reference
33
//
34
if (null is object)
35
return 4;
36
37
o = a;
38
if (!(o is int))
39
return 5;
40
41
if (d is int)
42
return 6;
43
44
System.Console.WriteLine ("Is tests pass");
45
return 0;
46
}
47
}