You've already forked linux-packaging-mono
Imported Upstream version 5.2.0.175
Former-commit-id: bb0468d0f257ff100aa895eb5fe583fb5dfbf900
This commit is contained in:
parent
4bdbaf4a88
commit
966bba02bb
30
mcs/tests/gtest-autoproperty-22.cs
Normal file
30
mcs/tests/gtest-autoproperty-22.cs
Normal file
@@ -0,0 +1,30 @@
|
||||
using System;
|
||||
|
||||
class MainClass
|
||||
{
|
||||
public static void Main()
|
||||
{
|
||||
Child test = new Child();
|
||||
}
|
||||
}
|
||||
|
||||
class Parent
|
||||
{
|
||||
protected virtual string Property { get; }
|
||||
}
|
||||
|
||||
class Child : Parent
|
||||
{
|
||||
protected override string Property { get; }
|
||||
|
||||
public Child ()
|
||||
{
|
||||
new AnotherClass{ field = Property = "success" };
|
||||
Console.WriteLine(Property);
|
||||
}
|
||||
}
|
||||
|
||||
class AnotherClass
|
||||
{
|
||||
public string field;
|
||||
}
|
||||
Reference in New Issue
Block a user