Beispiel #1
0
    public static int test_1_entry_vcall_unbox()
    {
        InterpOnlyIFace iface = new InterpOnlyStruct()
        {
            Field = 1
        };

        return(iface.get_Field2());
    }
Beispiel #2
0
    public static int test_1_entry_delegate_virtual_unbox()
    {
        var s = new InterpOnlyStruct()
        {
            Field = 1
        };
        InterpOnlyIFace iface = s;
        Func <int>      func  = iface.get_Field2;

        return(func());
    }
Beispiel #3
0
    public static int test_1_entry_delegate_unbox()
    {
        var s = new InterpOnlyStruct()
        {
            Field = 1
        };

        if (s.get_Field() != 1)
        {
            return(2);
        }
        Func <int> func = s.get_Field;

        return(func());
    }