2007-05-25 Jonathan Chambers <joncham@gmail.com>
[mcs.git] / tests / test-275.cs
blobf3f047b68b2b41dcf455815b2aedca8ebea66bf5
1 using System;
2 using System.Reflection;
3 using System.Runtime.CompilerServices;
5 public class Test
6 {
7 public delegate void DelType();
9 public event DelType MyEvent;
11 public static int Main()
13 EventInfo ei = typeof(Test).GetEvent ("MyEvent");
14 MethodImplAttributes methodImplAttributes = ei.GetAddMethod ().GetMethodImplementationFlags();
16 if ((methodImplAttributes & MethodImplAttributes.Synchronized) == 0) {
17 Console.WriteLine ("FAILED");
18 return 1;
21 methodImplAttributes = ei.GetRemoveMethod ().GetMethodImplementationFlags();
22 if ((methodImplAttributes & MethodImplAttributes.Synchronized) == 0) {
23 Console.WriteLine ("FAILED");
24 return 2;
27 return 0;