Ejemplo n.º 1
0
 public static int test_0_throw_child()
 {
     try {
         InterpClass.throw_ex();
     } catch {
         return(0);
     }
     return(1);
 }
Ejemplo n.º 2
0
    public static int entry()
    {
        InterpClass.entry_void_0();
        InterpClass.entry_void_0();
        int res = InterpClass.entry_int_int(1);

        if (res != 2)
        {
            return(1);
        }
        var c = new InterpClass();

        res = c.entry_int_this_int(1);
        if (res != 2)
        {
            return(2);
        }
        var s = InterpClass.entry_string_string("A", "B");

        if (s != "AB")
        {
            return(3);
        }
        var astruct = new AStruct()
        {
            i = 1
        };
        var astruct2 = InterpClass.entry_struct_struct(astruct);

        if (astruct2.i != 1)
        {
            return(4);
        }
        var l  = new List <string> ();
        var l2 = InterpClass.entry_ginst_ginst(l);

        if (l != l2)
        {
            return(5);
        }
        var gstruct = new GStruct <string> ()
        {
            i = 1
        };
        var gstruct2 = InterpClass.entry_ginst_ginst_vtype(gstruct);

        if (gstruct2.i != 1)
        {
            return(6);
        }
        int val = 1;

        InterpClass.entry_void_byref_int(ref val);
        if (val != 2)
        {
            return(7);
        }
        res = InterpClass.entry_8_int_args(1, 2, 3, 4, 5, 6, 7, 8);
        if (res != 36)
        {
            return(8);
        }
        res = InterpClass.entry_9_int_args(1, 2, 3, 4, 5, 6, 7, 8, 9);
        if (res != 45)
        {
            return(9);
        }
        var ptr  = new IntPtr(32);
        var ptr2 = InterpClass.entry_intptr_intptr(ptr);

        if (ptr != ptr2)
        {
            return(10);
        }
        return(0);
    }
Ejemplo n.º 3
0
 public static StackTrace get_stacktrace_jit2()
 {
     return(InterpClass.get_stacktrace_interp2());
 }