[LoongArch64] Part-5:add loongarch support in some files for LoongArch64. (#21769)
[mono-project.git] / mcs / tests / test-ref-05.cs
blob4848468cfda4c6eac578af6509d718cddf311ed8
1 class X
3 static int field;
5 public static int Main ()
7 Test () = 3;
9 if (field != (byte) 3)
10 return 1;
12 G<string>.Test (ref field) = 6;
13 if (field != 6)
14 return 2;
16 --Test ();
17 if (field != 5)
18 return 3;
20 Test (ref Test (), ref Test ());
22 return 0;
25 static ref int Test ()
27 return ref field;
30 static void Test<T> (ref T a, ref int b)
34 static void Test2<T> (ref T arg)
36 Test (ref arg, ref Test ());
40 class G<U>
42 public static ref T Test<T> (ref T arg)
44 return ref arg;