diff --git a/base/inference.jl b/base/inference.jl index c91cba2febb31..3008fef41e03a 100644 --- a/base/inference.jl +++ b/base/inference.jl @@ -802,6 +802,8 @@ function type_more_complex(t::ANY, c::ANY, sources::SimpleVector) end elseif t === c return false + elseif isa(t, Int) && isa(c, Int) + return t === 1 # alternatively: 0 <= t < c end return true end