projects
/
mono.git
/ blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
history
|
raw
|
HEAD
2005-02-08 Atsushi Enomoto <atsushi@ximian.com>
[mono.git]
/
mcs
/
tests
/
a-instance.cs
1
//
2
// Instance access.
3
//
4
using System;
5
6
delegate void D ();
7
8
class X {
9
static void Main ()
10
{
11
X x = new X (1);
12
X y = new X (100);
13
D a = x.T ();
14
D b = y.T ();
15
16
a ();
17
b ();
18
}
19
20
X (int start)
21
{
22
ins = start;
23
}
24
25
int ins;
26
27
D T ()
28
{
29
D d = delegate () {
30
Console.WriteLine ("My state is: " + ins);
31
};
32
33
return d;
34
}
35
}