human
I wrote the below code

    is_integer = isinstance(sig.args[0], types.Integer)
    tp = sig.return_type
    zerodiv_return = _get_power_zerodiv_return(context, tp)
    def int_power(a, b):
        r = tp(1)
        a = tp(a)
        if (b < 0):
            invert = True
            exp = (- b)
            if (exp < 0):
                raise OverflowError
            if is_integer:
                if (a == 0):
                    if zerodiv_return:
                        return zerodiv_return
                    else:
                        raise ZeroDivisionError('0    cannot    be    raised    to    a    negative    power')
                if ((a != 1) and (a != (-1))):
                    return 0
        else:
            invert = False
            exp = b
        if (exp > 65536):
            return math.pow(a, float(b))
        while (exp != 0):
            if (exp & 1):
                r *= a
            exp >>= 1
            a *= a
        return ((1.0 / r) if invert else r)
    res = context.compile_internal(builder, int_power, sig, args)
    return impl_ret_untracked(context, builder, sig.return_type, res)

What's a good function header?
 Here's a good function header?
assistant
#Here's a good function header.

def int_power_impl(context, builder, sig, args):