diff --git a/base/compiler/abstractinterpretation.jl b/base/compiler/abstractinterpretation.jl index f82380cecaa576..faa3c757d8c92a 100644 --- a/base/compiler/abstractinterpretation.jl +++ b/base/compiler/abstractinterpretation.jl @@ -263,6 +263,7 @@ function abstract_call_method_with_const_args(interp::AbstractInterpreter, @nosp if inf_result === nothing inf_result = InferenceResult(mi, argtypes) frame = InferenceState(inf_result, #=cache=#false, interp) + frame === nothing && return Any # this is probably a bad generated function (unsound), but just ignore it frame.limited = true frame.parent = sv push!(inf_cache, inf_result)