Skip to content

Latest commit

 

History

History
38 lines (32 loc) · 738 Bytes

cs0502.md

File metadata and controls

38 lines (32 loc) · 738 Bytes
description title ms.date f1_keywords helpviewer_keywords ms.assetid
Compiler Error CS0502
Compiler Error CS0502
07/20/2015
CS0502
CS0502
6cd6deda-73a1-42d8-893b-45a685e63380

Compiler Error CS0502

'member' cannot be both abstract and sealed

A class member cannot be both abstract and sealed.

The following sample generates CS0502:

// CS0502.cs  
public class B  
{  
   abstract public void F();  
}  
  
public class C : B  
{  
   abstract sealed override public void F()   // CS0502  
   {  
   }  
}  
  
public class CMain  
{  
    public static void Main()  
    { }  
}