예제 #1
0
 /// <summary>
 /// Call an instance method on a given type, taking zero arguments
 /// </summary>
 /// <typeparam name="TEmit"></typeparam>
 /// <typeparam name="TCallee"></typeparam>
 /// <param name="emitter"></param>
 /// <param name="methodName"></param>
 public static void CallRuntimeThis0 <TEmit, TCallee>(this OptimisingEmitter <TEmit> emitter, string methodName)
 {
     using (var local = emitter.DeclareLocal(typeof(TCallee), "CallRuntimeThis0_Callee", false))
     {
         emitter.StoreLocal(local);
         emitter.LoadLocalAddress(local, false);
         emitter.CallRuntimeN <TEmit, TCallee>(methodName);
     }
 }