def _unlit_non_poison(ty):
    """Apply unliteral(ty) and raise a TypingError if type is Poison.
    """
    out = unliteral(ty)
    if isinstance(out, types.Poison):
        m = f"Poison type used in arguments; got {out}"
        raise errors.TypingError(m)
    return out
Apply unliteral(ty) and raise a TypingError if type is Poison.
    
numba/core/types/functions.py