repo.or.cz
/
mcs.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
2010-06-21 Atsushi Enomoto <atsushi@ximian.com>
[mcs.git]
/
errors
/
cs1686-3.cs
blob
42f14369a7fae74c4b49d25f2435fe5cf71477dd
1
// CS1686: Local variable or parameter `i' cannot have their address taken and be used inside an anonymous method or lambda expression
2
// Line: 18
3
// Compiler options: -unsafe
4
5
unsafe struct
S
6
{
7
public int
i
;
8
}
9
10
class
C
11
{
12
unsafe delegate int
*
D
();
13
14
static void
Main
()
15
{
16
unsafe
{
17
S str
=
new
S
();
18
D d
=
delegate
{ return &str.i; }
;
19
}
20
}
21
}