-
-
Notifications
You must be signed in to change notification settings - Fork 5.7k
Closed
Labels
correctness bug ⚠Bugs that are likely to lead to incorrect results in user code without throwingBugs that are likely to lead to incorrect results in user code without throwingtypes and dispatchTypes, subtyping and method dispatchTypes, subtyping and method dispatch
Description
julia> Base._methods_by_ftype(Tuple{Core.TypeofBottom, Vararg}, 5, Base.get_world_counter())
Any[]
julia> Type{Core.Union{}} == Core.TypeofBottom
true
julia> Base._methods_by_ftype(Tuple{Type{Core.Union{}}, Int}, 5, Base.get_world_counter())
1-element Vector{Any}:
Core.MethodMatch(Tuple{Type{Union{}}, Int64}, svec(), Union{}(a...) @ Core boot.jl:321, true)
The Core.TypeofBottom
probably often gets normalized to Type{Core.Union{}}
so this doesn't get observed often, but I was noticing it leading to incorrect method invalidations during reloading.
Metadata
Metadata
Assignees
Labels
correctness bug ⚠Bugs that are likely to lead to incorrect results in user code without throwingBugs that are likely to lead to incorrect results in user code without throwingtypes and dispatchTypes, subtyping and method dispatchTypes, subtyping and method dispatch