2 using System
.Reflection
;
11 public void Clear () { }
14 public static int Main ()
16 var m1
= typeof (C
).GetMethod ("Clear");
17 Console
.WriteLine (m1
.Attributes
);
18 if (m1
.Attributes
!= (MethodAttributes
.Public
| MethodAttributes
.HideBySig
))
21 var m2
= typeof (C
).GetMethod ("I.Clear", BindingFlags
.NonPublic
| BindingFlags
.Instance
);
22 Console
.WriteLine (m2
.Attributes
);
23 if (m2
.Attributes
!= (MethodAttributes
.Private
| MethodAttributes
.HideBySig
| MethodAttributes
.Final
| MethodAttributes
.Virtual
| MethodAttributes
.VtableLayoutMask
))