Skip to content

Commit 411969d

Browse files
committed
static_which: actually add edges
1 parent 076855f commit 411969d

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

src/Tricks.jl

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -190,9 +190,9 @@ static_which(@nospecialize(f)) = static_which(f, Tuple{Vararg{Any}})
190190
else
191191
matched_method = match.method
192192
end
193-
193+
ci = create_codeinfo_with_returnvalue([Symbol("#self#"), :f, :_T, :throw_error], [:T], (:T,), :($matched_method))
194194
# Now we add the edges so if a method is defined this recompiles
195-
ci = create_codeinfo_with_returnvalue([Symbol("#self#"), :f, :_T, :throw_error], [:T], (:T,), :($matched_method))
195+
ci.edges = _method_table_all_edges_all_methods(f, T, world)
196196
return ci
197197
end
198198
@eval function static_which(@nospecialize(f) , @nospecialize(_T::Type{T}) , @nospecialize(throw_error::Union{Val{true}, Val{false}}=Val(false))) where {T <: Tuple}
@@ -214,6 +214,7 @@ else
214214
matched_method = match.method
215215
end
216216
ci = create_codeinfo_with_returnvalue([Symbol("#self#"), :f, :_T, :throw_error], [:T], (:T,), :($matched_method))
217+
ci.edges = _method_table_all_edges_all_methods(f, T, world)
217218
return ci
218219
end
219220
end

0 commit comments

Comments
 (0)