コード例 #1
0
        public DelegateMarshallingMethodThunk(TypeDesc owningType, TypeDesc delegateType, string name)
        {
            _owningType   = owningType;
            _delegateType = delegateType;
            MethodDesc invokeMethod = delegateType.GetMethod("Invoke", null);

            _name = name;
            _delegateSignature = invokeMethod.Signature;
            _methodIL          = PInvokeILEmitter.EmitIL(this, null);
            _signature         = ((PInvokeILStubMethodIL)_methodIL).NativeCallableSignature;
        }
 public override MethodIL EmitIL()
 {
     return(PInvokeILEmitter.EmitIL(this, default(PInvokeILEmitterConfiguration), _interopStateManager));
 }