Exemplo n.º 1
0
        internal static Instruction LoadLocalBoxed(int index)
        {
            if (s_loadLocalBoxed == null)
            {
                s_loadLocalBoxed = new Instruction[LocalInstrCacheSize];
            }

            if (index < s_loadLocalBoxed.Length)
            {
                return(s_loadLocalBoxed[index] ?? (s_loadLocalBoxed[index] = new LoadLocalBoxedInstruction(index)));
            }
            else
            {
                return(new LoadLocalBoxedInstruction(index));
            }
        }
Exemplo n.º 2
0
 internal static Instruction LoadLocalBoxed(int index)
 {
     if (InstructionList._loadLocalBoxed == null)
     {
         InstructionList._loadLocalBoxed = new Instruction[64];
     }
     if (index >= (int)InstructionList._loadLocalBoxed.Length)
     {
         return(new LoadLocalBoxedInstruction(index));
     }
     else
     {
         Instruction instruction  = InstructionList._loadLocalBoxed[index];
         Instruction instruction1 = instruction;
         if (instruction == null)
         {
             LoadLocalBoxedInstruction loadLocalBoxedInstruction = new LoadLocalBoxedInstruction(index);
             Instruction instruction2 = loadLocalBoxedInstruction;
             InstructionList._loadLocalBoxed[index] = loadLocalBoxedInstruction;
             instruction1 = instruction2;
         }
         return(instruction1);
     }
 }