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

test-263.cs « tests « mcs - github.com/mono/mono.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: d0a3b7473a8985eb64e2306e57a4843a6b8c7403 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
// Compiler options: -unsafe

using System;

class Test {
	public String GetString (byte[] bytes)
	{
                unsafe {
                    int* i;
                }
                
		unsafe {
			fixed (byte *ss = &bytes [0]) {
                                int* i;
				return new String ((sbyte*)ss, 0, bytes.Length);
			}
		}
	}
        
        public static void Main () {}
}