Beispiel #1
0
def _check_ovf(op, catch_arithmexic_exception=False):
    mapping = [('[mscorlib]System.OverflowException',
                'exceptions.OverflowError')]
    if catch_arithmexic_exception:
        mapping.append(('[mscorlib]System.ArithmeticException',
                        'exceptions.OverflowError'))
    return [MapException(op, mapping)]
Beispiel #2
0
def _check_ovf_zer(op):
    mapping = [
        ('[mscorlib]System.OverflowException', 'exceptions.OverflowError'),
        ('[mscorlib]System.DivideByZeroException',
         'exceptions.ZeroDivisionError'),
        ('[mscorlib]System.ArithmeticException', 'exceptions.OverflowError')
    ]
    return [MapException(op, mapping)]
Beispiel #3
0
def _check_zer(op):
    mapping = [('[mscorlib]System.DivideByZeroException',
                'exceptions.ZeroDivisionError')]
    return [MapException(op, mapping)]
Beispiel #4
0
def _check_ovf(op):
    mapping = [('[mscorlib]System.OverflowException',
                'exceptions.OverflowError')]
    return [MapException(op, mapping)]