internal static LeaveExceptionHandlerInstruction Create(int labelIndex, bool hasValue) { int num; if (labelIndex >= 32) { return(new LeaveExceptionHandlerInstruction(labelIndex, hasValue)); } else { int num1 = 2 * labelIndex; if (hasValue) { num = 1; } else { num = 0; } int num2 = num1 | num; LeaveExceptionHandlerInstruction cache = LeaveExceptionHandlerInstruction.Cache[num2]; LeaveExceptionHandlerInstruction leaveExceptionHandlerInstruction = cache; if (cache == null) { LeaveExceptionHandlerInstruction leaveExceptionHandlerInstruction1 = new LeaveExceptionHandlerInstruction(labelIndex, hasValue); LeaveExceptionHandlerInstruction leaveExceptionHandlerInstruction2 = leaveExceptionHandlerInstruction1; LeaveExceptionHandlerInstruction.Cache[num2] = leaveExceptionHandlerInstruction1; leaveExceptionHandlerInstruction = leaveExceptionHandlerInstruction2; } return(leaveExceptionHandlerInstruction); } }
internal static LeaveExceptionHandlerInstruction Create(int labelIndex, bool hasValue) { int num; if (labelIndex >= 32) { return new LeaveExceptionHandlerInstruction(labelIndex, hasValue); } else { int num1 = 2 * labelIndex; if (hasValue) { num = 1; } else { num = 0; } int num2 = num1 | num; LeaveExceptionHandlerInstruction cache = LeaveExceptionHandlerInstruction.Cache[num2]; LeaveExceptionHandlerInstruction leaveExceptionHandlerInstruction = cache; if (cache == null) { LeaveExceptionHandlerInstruction leaveExceptionHandlerInstruction1 = new LeaveExceptionHandlerInstruction(labelIndex, hasValue); LeaveExceptionHandlerInstruction leaveExceptionHandlerInstruction2 = leaveExceptionHandlerInstruction1; LeaveExceptionHandlerInstruction.Cache[num2] = leaveExceptionHandlerInstruction1; leaveExceptionHandlerInstruction = leaveExceptionHandlerInstruction2; } return leaveExceptionHandlerInstruction; } }
internal static LeaveExceptionHandlerInstruction Create(int labelIndex, bool hasValue) { if (labelIndex < CacheSize) { int index = (2 * labelIndex) | (hasValue ? 1 : 0); return(s_cache[index] ?? (s_cache[index] = new LeaveExceptionHandlerInstruction(labelIndex, hasValue))); } return(new LeaveExceptionHandlerInstruction(labelIndex, hasValue)); }
public void EmitLeaveExceptionHandler(bool hasValue, BranchLabel tryExpressionEndLabel) { Emit(LeaveExceptionHandlerInstruction.Create(EnsureLabelIndex(tryExpressionEndLabel), hasValue)); }
internal static LeaveExceptionHandlerInstruction Create(int labelIndex, bool hasValue) { if (labelIndex < CacheSize) { int index = (2 * labelIndex) | (hasValue ? 1 : 0); return s_cache[index] ?? (s_cache[index] = new LeaveExceptionHandlerInstruction(labelIndex, hasValue)); } return new LeaveExceptionHandlerInstruction(labelIndex, hasValue); }