Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
'class member' cannot declare a body because it is marked abstract
An abstract method cannot contain its implementation.
The following sample generates CS0500:
// CS0500.cs
namespace x
{
abstract public class clx
{
abstract public void f(){} // CS0500
// try the following line instead
// abstract public void f();
}
public class cly
{
public static int Main()
{
return 0;
}
}
}
Collaborate with us on GitHub
The source for this content can be found on GitHub, where you can also create and review issues and pull requests. For more information, see our contributor guide.