internal void GenerateLoadAddress(ParameterStructure param) { int index = param.GainPosition(); if (index <= 255) { Generator.Emit(OpCodes.Ldarga_S, index); } else { Generator.Emit(OpCodes.Ldarga, index); } }
internal void GenerateStore(ParameterStructure param) { int index = param.GainPosition(); if (index <= 255) { Generator.Emit(OpCodes.Starg_S, index); } else { Generator.Emit(OpCodes.Starg, index); } }
internal void GenerateLoad(ParameterStructure param) { int index = param.GainPosition(); if (index <= 255) { switch (index) { case 0: Generator.Emit(OpCodes.Ldarg_0); break; case 1: Generator.Emit(OpCodes.Ldarg_1); break; case 2: Generator.Emit(OpCodes.Ldarg_2); break; case 3: Generator.Emit(OpCodes.Ldarg_3); break; default: Generator.Emit(OpCodes.Ldarg_S, index); break; } } else { Generator.Emit(OpCodes.Ldarg, index); } }