a575963da9
Former-commit-id: da6be194a6b1221998fc28233f2503bd61dd9d14
42 lines
514 B
C#
42 lines
514 B
C#
// CS0120: An object reference is required to access non-static member `TestNamespace.TestClass.HelloWorld()'
|
|
// Line: 31
|
|
|
|
using System;
|
|
using TestNamespace;
|
|
|
|
namespace TestNamespace
|
|
{
|
|
public class TestClass
|
|
{
|
|
public void HelloWorld ()
|
|
{
|
|
}
|
|
}
|
|
}
|
|
|
|
class SuperClass
|
|
{
|
|
TestClass tc = null;
|
|
|
|
TestClass TestClass
|
|
{
|
|
get { return tc; }
|
|
}
|
|
}
|
|
|
|
class SubClass : SuperClass
|
|
{
|
|
public SubClass ()
|
|
{
|
|
TestClass.HelloWorld ();
|
|
}
|
|
}
|
|
|
|
class App
|
|
{
|
|
public static void Main ()
|
|
{
|
|
SubClass sc = new SubClass ();
|
|
}
|
|
}
|