2 using System.Reflection;
7 // Math.Sin is a "public" internal call for both Mono and Microsoft
8 private const string icall = "Sin";
10 static int TestReflectedICall ()
12 MethodInfo mi = typeof (System.Math).GetMethod (icall);
14 Console.WriteLine ("*3* Couldn't reflect on internalcall {0}", icall);
18 return (int) (double) mi.Invoke (null, new object [1] { 0.0 });
24 int result = TestReflectedICall ();
25 Console.WriteLine ("*{0}* [Reflected]System.Math.Sin(0) == {0}", result);
28 catch (SecurityException se) {
29 Console.WriteLine ("*1* SecurityException\n{0}", se);
33 Console.WriteLine ("*2* Unexpected exception\n{0}", e);