'Given a return *code*, get a Status instance.'

def _get_return_status(self, builder, code):

    norm = builder.icmp_signed('==', code, RETCODE_OK)
    none = builder.icmp_signed('==', code, RETCODE_NONE)
    ok = builder.or_(norm, none)
    err = builder.not_(ok)
    exc = builder.icmp_signed('==', code, RETCODE_EXC)
    is_stop_iteration = builder.icmp_signed('==', code, RETCODE_STOPIT)
    is_user_exc = builder.icmp_signed('>=', code, RETCODE_USEREXC)
    status = Status(code=code, is_ok=ok, is_error=err, is_python_exc=exc, is_none=none, is_user_exc=is_user_exc, is_stop_iteration=is_stop_iteration, excinfoptr=None)
    return status
