We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent cd6c5cf commit 10d9545Copy full SHA for 10d9545
Sources/SwiftSyntax/Syntax.swift
@@ -70,10 +70,12 @@ public struct Syntax: SyntaxProtocol, SyntaxHashable {
70
}
71
72
public var id: SyntaxIdentifier {
73
- SyntaxIdentifier(
74
- rootId: UInt(rawID: arena.root.pointee.raw.id),
75
- indexInTree: SyntaxIdentifier.SyntaxIndexInTree(indexInTree: absoluteInfo.indexInTree)
76
- )
+ withExtendedLifetime(self) { // 'withExtendedLifetime' for a potential compiler bug (rdar://141977987)
+ SyntaxIdentifier(
+ rootId: UInt(rawID: arena.root.pointee.raw.id),
+ indexInTree: SyntaxIdentifier.SyntaxIndexInTree(indexInTree: absoluteInfo.indexInTree)
77
+ )
78
+ }
79
80
81
/// The position of the start of this node's leading trivia
0 commit comments