Skip to content

Commit bb52b40

Browse files
committed
Use updated spelling for lifetime annotations.
1 parent b2ab762 commit bb52b40

File tree

3 files changed

+6
-6
lines changed

3 files changed

+6
-6
lines changed

Package.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -147,7 +147,7 @@ let package = Package(
147147
] + wasiLibcCSettings,
148148
swiftSettings: [
149149
.enableExperimentalFeature("VariadicGenerics"),
150-
.enableExperimentalFeature("LifetimeDependence"),
150+
.enableExperimentalFeature("Lifetimes"),
151151
.enableExperimentalFeature("AddressableTypes"),
152152
.enableExperimentalFeature("AllowUnsafeAttribute"),
153153
.enableExperimentalFeature("BuiltinModule"),

Sources/FoundationEssentials/CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,7 @@ endif()
8181

8282
target_compile_options(FoundationEssentials PRIVATE
8383
"SHELL:$<$<COMPILE_LANGUAGE:Swift>:-Xfrontend -enable-experimental-feature -Xfrontend VariadicGenerics>"
84-
"SHELL:$<$<COMPILE_LANGUAGE:Swift>:-Xfrontend -enable-experimental-feature -Xfrontend LifetimeDependence>"
84+
"SHELL:$<$<COMPILE_LANGUAGE:Swift>:-Xfrontend -enable-experimental-feature -Xfrontend Lifetimes>"
8585
"SHELL:$<$<COMPILE_LANGUAGE:Swift>:-Xfrontend -enable-experimental-feature -Xfrontend AddressableTypes>"
8686
"SHELL:$<$<COMPILE_LANGUAGE:Swift>:-Xfrontend -enable-experimental-feature -Xfrontend BuiltinModule>"
8787
"SHELL:$<$<COMPILE_LANGUAGE:Swift>:-Xfrontend -enable-experimental-feature -Xfrontend AccessLevelOnImport>"

Sources/FoundationEssentials/Data/Data.swift

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2206,7 +2206,7 @@ public struct Data : Equatable, Hashable, RandomAccessCollection, MutableCollect
22062206
@available(macOS 10.14.4, iOS 12.2, watchOS 5.2, tvOS 12.2, *)
22072207
@_alwaysEmitIntoClient
22082208
public var bytes: RawSpan {
2209-
@lifetime(borrow self)
2209+
@_lifetime(borrow self)
22102210
borrowing get {
22112211
let buffer: UnsafeRawBufferPointer
22122212
switch _representation {
@@ -2234,7 +2234,7 @@ public struct Data : Equatable, Hashable, RandomAccessCollection, MutableCollect
22342234
@available(macOS 10.14.4, iOS 12.2, watchOS 5.2, tvOS 12.2, *)
22352235
@_alwaysEmitIntoClient
22362236
public var span: Span<UInt8> {
2237-
@lifetime(borrow self)
2237+
@_lifetime(borrow self)
22382238
borrowing get {
22392239
let span = unsafe bytes._unsafeView(as: UInt8.self)
22402240
return _overrideLifetime(span, borrowing: self)
@@ -2244,7 +2244,7 @@ public struct Data : Equatable, Hashable, RandomAccessCollection, MutableCollect
22442244
@available(macOS 10.14.4, iOS 12.2, watchOS 5.2, tvOS 12.2, *)
22452245
@_alwaysEmitIntoClient
22462246
public var mutableBytes: MutableRawSpan {
2247-
@lifetime(&self)
2247+
@_lifetime(&self)
22482248
mutating get {
22492249
let buffer: UnsafeMutableRawBufferPointer
22502250
switch _representation {
@@ -2272,7 +2272,7 @@ public struct Data : Equatable, Hashable, RandomAccessCollection, MutableCollect
22722272
@available(macOS 10.14.4, iOS 12.2, watchOS 5.2, tvOS 12.2, *)
22732273
@_alwaysEmitIntoClient
22742274
public var mutableSpan: MutableSpan<UInt8> {
2275-
@lifetime(&self)
2275+
@_lifetime(&self)
22762276
mutating get {
22772277
#if false // see https://github.com/swiftlang/swift/issues/81218
22782278
var bytes = mutableBytes

0 commit comments

Comments
 (0)