Skip to content

Commit

Permalink
Print whether call or invoke in showerror
Browse files Browse the repository at this point in the history
  • Loading branch information
apaz-cli authored and maleadt committed Nov 18, 2022
1 parent 22f58fc commit ab88ba3
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion base/errorshow.jl
Original file line number Diff line number Diff line change
Expand Up @@ -262,7 +262,11 @@ function showerror(io::IO, ex::MethodError)
if ft <: Function && isempty(ft.parameters) && _isself(ft)
f_is_function = true
end
print(io, "no method matching ")
if is_arg_types
print(io, "no method matching for invoke of ")
else
print(io, "no method matching for call to ")
end
show_signature_function(io, isa(f, Type) ? Type{f} : typeof(f))
show_tuple_as_call(io, :function, arg_types; hasfirst=false, kwargs = !isempty(kwargs) ? Any[(k, typeof(v)) for (k, v) in kwargs] : nothing)
end
Expand Down

0 comments on commit ab88ba3

Please sign in to comment.