예제 #1
0
        private void callMixinVirtual()
        {
            FPod.NMethod ncall  = pod.ncall(u2(), FConst.CallMixinVirtual);
            Method       method = emitter.findMethod(ncall.parentType, ncall.methodName,
                                                     ncall.paramTypes, ncall.returnType);

            method.AddCallConv(CallConv.Instance);
            code.MethInst(MethodOp.callvirt, method);
        }
예제 #2
0
        private void callVirtual()
        {
            int index = u2();

            FPod.NMethod ncall  = pod.ncall(index, FConst.CallVirtual);
            Method       method = emitter.findMethod(ncall.parentType, ncall.methodName,
                                                     ncall.paramTypes, ncall.returnType);

            if (ncall.isStatic)
            {
                code.MethInst(MethodOp.call, method);
            }
            else
            {
                method.AddCallConv(CallConv.Instance);
                code.MethInst(MethodOp.callvirt, method);
            }
        }