Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions base/essentials.jl
Original file line number Diff line number Diff line change
Expand Up @@ -857,6 +857,9 @@ e.g. long-running event loops or callback functions that may
call obsolete versions of a function `f`.
(The drawback is that `invokelatest` is somewhat slower than calling
`f` directly, and the type of the result cannot be inferred by the compiler.)

!!! compat "Julia 1.9"
Prior to Julia 1.9, this function was not exported, and was called as `Base.invokelatest`.
"""
function invokelatest(@nospecialize(f), @nospecialize args...; kwargs...)
kwargs = merge(NamedTuple(), kwargs)
Expand Down
5 changes: 4 additions & 1 deletion base/reflection.jl
Original file line number Diff line number Diff line change
Expand Up @@ -2157,7 +2157,7 @@ end
"""
@invokelatest f(args...; kwargs...)

Provides a convenient way to call [`Base.invokelatest`](@ref).
Provides a convenient way to call [`invokelatest`](@ref).
`@invokelatest f(args...; kwargs...)` will simply be expanded into
`Base.invokelatest(f, args...; kwargs...)`.

Expand Down Expand Up @@ -2187,6 +2187,9 @@ julia> @macroexpand @invokelatest xs[i] = v
!!! compat "Julia 1.7"
This macro requires Julia 1.7 or later.

!!! compat "Julia 1.9"
Prior to Julia 1.9, this macro was not exported, and was called as `Base.@invokelatest`.

!!! compat "Julia 1.10"
The additional syntax is supported as of Julia 1.10.
"""
Expand Down