2010-04-13 Sebastien Pouliot <sebastien@ximian.com>
[mono-project.git] / mcs / tests / test-736.cs
blob0813d2935e2eed473717f1879c4a9efa499a940f
1 // Compiler options: -warn:4 -warnaserror
3 using System;
5 // Nothing wrong with this, gmcs says otherwise
6 // Class is generic
7 public class TestGeneric<T>
9 public event EventHandler Event;
11 public void Raise ()
13 Event (this, EventArgs.Empty);
17 // Nothing wrong with this, gmcs concurs
18 // Note that T is used in the delegate signature for Event
19 public class TestGeneric2<T>
21 public delegate void GenericHandler (T t);
22 public event GenericHandler Event;
24 public void Raise ()
26 Event (default (T));
30 // Nothing wrong with this, gmcs concurs
31 // Class is not generic
32 public class Test
34 public event EventHandler Event;
36 public void Raise ()
38 Event (this, EventArgs.Empty);
41 public static void Main ()