Merge pull request #5714 from alexischr/update_bockbuild
[mono.git] / mcs / tests / test-93.cs
1 //
2 // This tests member lookups on inherited interfaces.
3 //
4 // The bug was exposed because FindMembers in MemberLookup
5 // would not return all the members on interfaces, but only
6 // the members from the most close type.
7 //
8
9 using System;
10 using System.Collections;
11
12 namespace N1
13 {       
14         interface A
15         {
16                 void method1 ();
17         }
18         
19         interface B:A
20         {
21                 void method2 ();
22         }
23
24         public class C
25         {
26                 void method (ref B p)
27                 {
28                         p.method2();//<- works declared in 'B'
29                         p.method1();//<- fails declared in 'A'
30                 }
31         }
32 }
33
34
35 class Test {
36         public static int Main () {
37                 IList list = new ArrayList ();
38                 int n = list.Count;
39
40                 return 0;
41         }
42 }
43
44
45
46
47