private void ComputeExceptionHandlerStackSize(ref Dictionary <Instruction, int> stack_sizes)
{
Collection <ExceptionHandler> exceptionHandlers = this.body.ExceptionHandlers;
for (int i = 0; i < exceptionHandlers.Count; i++)
{
ExceptionHandler item = exceptionHandlers[i];
ExceptionHandlerType handlerType = item.HandlerType;
if (handlerType == ExceptionHandlerType.Catch)
{
CodeWriter.AddExceptionStackSize(item.HandlerStart, ref stack_sizes);
}
else if (handlerType == ExceptionHandlerType.Filter)
{
CodeWriter.AddExceptionStackSize(item.FilterStart, ref stack_sizes);
CodeWriter.AddExceptionStackSize(item.HandlerStart, ref stack_sizes);
}
}
}