remove NotWorking
[mcs.git] / tests / test-567.cs
blob179420c0098cae30935ba5631d6627b9ea5c71e3
1 using System;
2 using System.Reflection;
3 using System.Runtime.InteropServices;
5 namespace preservesig_test
7 class Class1
9 static int Main(string[] args)
11 MethodInfo dofoo = typeof(TestClass).GetMethod("DoFoo");
12 if ((dofoo.GetMethodImplementationFlags() & MethodImplAttributes.PreserveSig) == 0)
13 return 1;
15 dofoo = typeof(TestClass).GetProperty("Foo").GetGetMethod ();
16 if ((dofoo.GetMethodImplementationFlags() & MethodImplAttributes.PreserveSig) == 0)
17 return 1;
19 dofoo = typeof(TestClass).GetEvent("e").GetAddMethod (true);
20 if ((dofoo.GetMethodImplementationFlags() & MethodImplAttributes.PreserveSig) == 0)
21 return 1;
23 Console.WriteLine("Has PreserveSig");
24 return 0;
28 public class TestClass
30 public delegate void D ();
32 [method:PreserveSig]
33 public event D e;
35 [PreserveSig()]
36 public int DoFoo()
38 return 0;
41 public int Foo {
42 [PreserveSig]
43 get {
44 return 2;