X-Git-Url: http://wien.tomnetworks.com/gitweb/?a=blobdiff_plain;f=mcs%2Ftests%2Ftest-181.cs;h=526f238285fea10be61d84ad175f8618e6633a13;hb=77515455734ec5dc00f4550a60a394f8b5a2a36a;hp=a2d5de1d680bf3c9ba0bc9416bec6204c8e430d9;hpb=f1f8b8a867c800b21b6a03767252403c2f72cae2;p=mono.git diff --git a/mcs/tests/test-181.cs b/mcs/tests/test-181.cs index a2d5de1d680..526f238285f 100644 --- a/mcs/tests/test-181.cs +++ b/mcs/tests/test-181.cs @@ -14,10 +14,41 @@ class Test { } - static public int Main () + [MethodImplAttribute((short)MethodImplOptions.Synchronized)] + public void test2 () { - MethodImplAttributes iflags = typeof (Test).GetMethod ("test").GetMethodImplementationFlags (); - return ((iflags & MethodImplAttributes.Synchronized) != 0 ? 0 : 1); + } + + [MethodImplAttribute((byte)32)] + public void test3 () + { + } + + [MethodImpl(MethodImplOptions.NoInlining | MethodImplOptions.NoOptimization)] + public void test4 () + { + } + + public static int Main () + { + MethodImplAttributes iflags; + iflags = typeof (Test).GetMethod ("test").GetMethodImplementationFlags (); + if ((iflags & MethodImplAttributes.Synchronized) == 0) + return 1; + + iflags = typeof (Test).GetMethod ("test2").GetMethodImplementationFlags (); + if ((iflags & MethodImplAttributes.Synchronized) == 0) + return 2; + + iflags = typeof (Test).GetMethod ("test3").GetMethodImplementationFlags (); + if ((iflags & MethodImplAttributes.Synchronized) == 0) + return 3; + + iflags = typeof (Test).GetMethod ("test3").GetMethodImplementationFlags (); + if ((iflags & MethodImplAttributes.Synchronized) == 0) + return 4; + + return 0; } }