Welcome to mirror list, hosted at ThFree Co, Russian Federation.

cs0212-3.cs « errors « mcs - github.com/mono/mono.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 03f6562406e63345746c5992f8c909bd72d45aa9 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
// cs0212-3.cs: You can only take the address of unfixed expression inside of a fixed statement initializer
// Line: 10
// Compiler options: -unsafe

struct Foo {
	public float f;
	public void foo ()
	{
		unsafe {
			float *pf1 = &f;
		}
	}
}

class Test {
	static void Main ()
	{
		Foo x = new Foo ();
		x.foo ();
	}
}