Skip to content

Commit ac33a8c

Browse files
committed
Conform Identifier to Sendable and Hashable
This isn't explicitly needed for this problem but it seems as though the default for all types that can conform to Sendable/Hashable should This also sets up this new type for Swift 6.0 (and the current Swift 5.10) to pass this type around safely when needed As well as allows Identifier to be a key in a dictionary which could be a common scenario
1 parent 9561184 commit ac33a8c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Sources/SwiftSyntax/Identifier.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
//===----------------------------------------------------------------------===//
1212

1313
/// An abstraction for sanitized values on a token.
14-
public struct Identifier: Equatable {
14+
public struct Identifier: Equatable, Hashable, Sendable {
1515
/// The sanitized `text` of a token.
1616
public let name: String
1717

0 commit comments

Comments
 (0)