컴파일러 오류 CS0074

업데이트: 2007년 11월

오류 메시지

'event': 추상 이벤트에는 이니셜라이저를 사용할 수 없습니다.
'event': abstract event cannot have initializer

eventabstract로 표시하면 초기화 할 수 없습니다. 자세한 내용은 이벤트(C# 프로그래밍 가이드)를 참조하십시오.

다음 샘플에서는 CS0074 오류가 발생하는 경우를 보여 줍니다.

// CS0074.cs
delegate void D();

abstract class Test
{
   public abstract event D e = null;   // CS0074
   // try the following line instead
   // public abstract event D e;

   public static void Main()
   {
   }
}