def METHOD_NAME(self, result_name: str) -> "UndefinedNeverFail":  # type: ignore
    # Record that this undefined variable was actually used.
    UndefinedNeverFail.all_undefined_names.append(self._undefined_name)
    return UndefinedNeverFail(
        hint=self._undefined_hint,
        obj=self._undefined_obj,
        name=result_name,
        exc=self._undefined_exception,
    )