Beispiel #1
0
def unsafe_fxquotient(a, b):
    return values.W_Fixnum(rarithmetic.int_c_div(a.value, b.value))
Beispiel #2
0
def unsafe_fxquotient(a, b):
    return values.W_Fixnum(rarithmetic.int_c_div(a.value, b.value))
Beispiel #3
0
def int_floordiv(space, n, m):
    return space.wrap(int_c_div(n, m))
Beispiel #4
0
def int_floordiv(space, n, m):
    return space.newint(int_c_div(n, m))
Beispiel #5
0
def int_floordiv_ovf(x, y):
    # JIT: intentionally not short-circuited to produce only one guard
    # and to remove the check fully if one of the arguments is known
    if (x == -sys.maxint - 1) & (y == -1):
        raise OverflowError("integer division")
    return int_c_div(x, y)