-// Test for bug #60459
+// Compiler options: -warnaserror -warn:4
using System;
using System.Reflection;
-public class EventTestClass {
- public event EventHandler Elapsed;
+public class EventTestClass : IEventTest {
+ public event EventHandler Elapsed; // No warning is reported
}
public interface IEventTest {
public class EntryPoint
{
- static bool test (Type type) { return type.GetEvent ("Elapsed").IsSpecialName; }
+ public static bool test (Type type) { return type.GetEvent ("Elapsed").IsSpecialName; }
public static int Main ()
{
return (test (typeof (EventTestClass))