Files
swift-mirror/test/ModuleInterface
Andrew Trick b7e2186f7d Support @_lifetime(immortal) to suppress inout default dependency
Non-Escapable 'inout' arguments have a default self-dependency, regardless of
any other annotations.  For example:

    @_lifetime(dest: copy source)
    /* DEFAULT: @_lifetime(dest: copy dest, copy source) */
    func foo<T: ~Escapable>(dest: inout T, source: T)

An immortal lifetime specifier now suppresses that default. For example:

    @_lifetime(dest: immortal, copy source)
    /* DEFAULT: @_lifetime(dest: copy source) */
    func foo<T: ~Escapable>(dest: inout T, source: T)

This is necessary because there is otherwise no other way to suppress the
default lifetime.

Fixes rdar://170016708 ([nonescapable] Support @_lifetime(immortal) to suppress
the usual inout default self-dependency)
2026-02-11 05:55:26 -08:00
..
2025-05-05 13:50:51 -07:00
2024-11-18 18:09:19 -08:00
2024-02-08 14:29:05 -07:00