https://github.com/JuliaLang/julia
Raw File
Tip revision: 3348de4ea601f78f6c29c8588a7aa36031e75258 authored by Kristoffer Carlsson on 15 November 2021, 08:22:49 UTC
release-1.7: set VERSION to 1.7-rc3 (#43070)
Tip revision: 3348de4
opaque_closure.jl
"""
    @opaque (args...) -> body

Marks a given closure as "opaque". Opaque closures capture the
world age of their creation (as opposed to their invocation).
This allows for more aggressive optimization of the capture
list, but trades off against the ability to inline opaque
closures at the call site, if their creation is not statically
visible.

!!! warning
    This interface is experimental and subject to change or removal without notice.
"""
macro opaque(ex)
    esc(Expr(:opaque_closure, ex))
end
back to top