Update PointConverter.cs
[mono.git] / mcs / tests / dtest-error-02.cs
1 using System;
2 using Microsoft.CSharp.RuntimeBinder;
3
4 class A
5 {
6         private class N
7         {
8                 public void Foo ()
9                 {
10                 }
11         }
12         
13         public static dynamic Factory ()
14         {
15                 return new N ();
16         }
17 }
18
19 public class Test
20 {
21         public static int Main ()
22         {
23                 dynamic d = A.Factory ();
24                 
25                 try {
26                         d.Foo ();
27                         return 1;
28                 } catch (RuntimeBinderException e) {
29                         if (e.Message != "`A.N.Foo()' is inaccessible due to its protection level")
30                                 return 2;
31                 }
32                 
33                 return 0;
34         }
35 }