diff --git a/stdlib/public/core/StringUTF8View.swift b/stdlib/public/core/StringUTF8View.swift index 41e90fc6f92..f894bbb0ca6 100644 --- a/stdlib/public/core/StringUTF8View.swift +++ b/stdlib/public/core/StringUTF8View.swift @@ -330,7 +330,7 @@ extension String.UTF8View { let span = unsafe Span(_unsafeStart: start, count: count) return unsafe _overrideLifetime(span, borrowing: self) } -#endif +#endif // _runtime(_ObjC) let count = _guts.count if _guts.isSmall { let a = Builtin.addressOfBorrow(self) @@ -384,7 +384,7 @@ extension String.UTF8View { span } } -#else +#else // !(os(watchOS) && _pointerBitWidth(_32)) @available(watchOS, unavailable) public var span: Span { @lifetime(borrow self) @@ -415,7 +415,7 @@ extension String.UTF8View { return _underlyingSpan() } } -#endif +#endif // !(os(watchOS) && _pointerBitWidth(_32)) } // Index conversions diff --git a/stdlib/public/core/Substring.swift b/stdlib/public/core/Substring.swift index 60db561adb8..b5b08a28b4b 100644 --- a/stdlib/public/core/Substring.swift +++ b/stdlib/public/core/Substring.swift @@ -763,7 +763,7 @@ extension Substring.UTF8View { let span = base._underlyingSpan()._extracting(first..<(first &+ count)) return unsafe _overrideLifetime(span, borrowing: self) } -#endif +#endif // _runtime(_ObjC) let first = _slice._startIndex._encodedOffset let end = _slice._endIndex._encodedOffset if _wholeGuts.isSmall { @@ -839,7 +839,7 @@ extension Substring.UTF8View { span } } -#else +#else // !(os(watchOS) && _pointerBitWidth(_32)) @available(watchOS, unavailable) public var span: Span { fatalError("\(#function) unavailable on 32-bit watchOS") @@ -878,7 +878,7 @@ extension Substring.UTF8View { return _underlyingSpan() } } -#endif +#endif // !(os(watchOS) && _pointerBitWidth(_32)) } extension Substring { diff --git a/stdlib/public/core/UTF8Span.swift b/stdlib/public/core/UTF8Span.swift index 6117c273e17..04941a44a4c 100644 --- a/stdlib/public/core/UTF8Span.swift +++ b/stdlib/public/core/UTF8Span.swift @@ -213,7 +213,7 @@ extension String { let span = unsafe Span(_unsafeStart: start, count: count) return unsafe _overrideLifetime(span, borrowing: self) } -#endif +#endif // _runtime(_ObjC) let count = _guts.count if _guts.isSmall { let a = Builtin.addressOfBorrow(self) @@ -269,7 +269,7 @@ extension String { utf8Span } } -#else +#else // !(os(watchOS) && _pointerBitWidth(_32)) @available(watchOS, unavailable) public var utf8Span: UTF8Span { fatalError("\(#function) unavailable on 32-bit watchOS") @@ -299,7 +299,7 @@ extension String { ) } } -#endif +#endif // !(os(watchOS) && _pointerBitWidth(_32)) } @available(SwiftStdlib 6.2, *) @@ -316,7 +316,7 @@ extension Substring { let span = base._underlyingSpan()._extracting(first..<(first &+ count)) return unsafe _overrideLifetime(span, borrowing: self) } -#endif +#endif // _runtime(_ObjC) let first = _slice._startIndex._encodedOffset let end = _slice._endIndex._encodedOffset if _wholeGuts.isSmall { @@ -394,7 +394,7 @@ extension Substring { utf8Span } } -#else +#else // !(os(watchOS) && _pointerBitWidth(_32)) @available(watchOS, unavailable) public var utf8Span: UTF8Span { fatalError("\(#function) unavailable on 32-bit watchOS") @@ -435,5 +435,5 @@ extension Substring { ) } } -#endif +#endif // !(os(watchOS) && _pointerBitWidth(_32)) }