Example #1
0
def pow__SmallInt_SmallInt_SmallInt(space, w_int1, w_int2, w_int3):
    from pypy.objspace.std.intobject import _impl_int_int_pow
    x = w_int1.intval
    y = w_int2.intval
    z = w_int3.intval
    if z == 0:
        raise OperationError(space.w_ValueError,
                             space.wrap("pow() 3rd argument cannot be 0"))
    return _impl_int_int_pow(space, x, y, z)
Example #2
0
def pow__SmallInt_SmallInt_None(space, w_int1, w_int2, w_int3):
    from pypy.objspace.std.intobject import _impl_int_int_pow
    x = w_int1.intval
    y = w_int2.intval
    return _impl_int_int_pow(space, x, y)