Skip to content

stdlib: remove all FIXME(sil-serialize-all) attributes in StringSwitch.swift #20477

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Nov 9, 2018
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
7 changes: 0 additions & 7 deletions stdlib/public/core/StringSwitch.swift
Original file line number Diff line number Diff line change
Expand Up @@ -39,13 +39,9 @@ struct _OpaqueStringSwitchCache {
var b: Builtin.Word
}

@usableFromInline // FIXME(sil-serialize-all)
internal typealias _StringSwitchCache = Dictionary<String, Int>

@_fixed_layout // FIXME(sil-serialize-all)
@usableFromInline // FIXME(sil-serialize-all)
internal struct _StringSwitchContext {
@inlinable // FIXME(sil-serialize-all)
internal init(
cases: [StaticString],
cachePtr: UnsafeMutablePointer<_StringSwitchCache>
Expand All @@ -54,9 +50,7 @@ internal struct _StringSwitchContext {
self.cachePtr = cachePtr
}

@usableFromInline // FIXME(sil-serialize-all)
internal let cases: [StaticString]
@usableFromInline // FIXME(sil-serialize-all)
internal let cachePtr: UnsafeMutablePointer<_StringSwitchCache>
}

Expand Down Expand Up @@ -94,7 +88,6 @@ func _findStringSwitchCaseWithCache(
}

/// Builds the string switch case.
@inlinable // FIXME(sil-serialize-all)
internal func _createStringTableCache(_ cacheRawPtr: Builtin.RawPointer) {
let context = UnsafePointer<_StringSwitchContext>(cacheRawPtr).pointee
var cache = _StringSwitchCache()
Expand Down
3 changes: 3 additions & 0 deletions test/api-digester/Outputs/stability-stdlib-abi.swift.expected
Original file line number Diff line number Diff line change
Expand Up @@ -81,3 +81,6 @@ Func _makeAnyHashableUpcastingToHashableBaseType(_:storingResultInto:) has been

Func RandomNumberGenerator._fill(bytes:) has been removed
Func SystemRandomNumberGenerator._fill(bytes:) has been removed

Func _createStringTableCache(_:) has been removed
Struct _StringSwitchContext has been removed