[mcs] Allow properties and indexers of by-ref values to be set without setter
[mono.git] / mcs / errors / cs1540-10.cs
1 // CS1540: Cannot access protected member `Test.A.Property' via a qualifier of type `Test.A'. The qualifier must be of type `Test.B.C' or derived from it
2 // Line: 19
3
4 namespace Test
5 {
6     public class A
7     {
8         protected int Property {
9             get { return 0; }
10         }
11     }
12  
13     public class B : A
14     {
15         private sealed class C
16         {
17             public C (A a)
18             {
19                 int test = a.Property;
20                 test++;
21             }
22         }
23     } 
24 }