Skip to content

Commit 6fe6760

Browse files
committed
Check for Method return from jl_gf_invoke_lookup
Fixes timholy/Revise.jl#515 Changed in JuliaLang/julia#35983
1 parent f65e021 commit 6fe6760

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

src/utils.jl

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,7 @@ function whichtt(@nospecialize(tt))
3434
# TODO: provide explicit control over world age? In case we ever need to call "old" methods.
3535
m = ccall(:jl_gf_invoke_lookup, Any, (Any, UInt), tt, typemax(UInt))
3636
m === nothing && return nothing
37+
isa(m, Method) && return m
3738
return m.func::Method
3839
end
3940

0 commit comments

Comments
 (0)