mirror of
https://github.com/apple/swift.git
synced 2025-12-21 12:14:44 +01:00
- Stop producing 'backtick' trivia for escaping identifier token. '`'s are now parts of the token text - Adjust and simplify C++ libSyntax APIs - Add 'is_deprecated' property to Trivia.py to attribute SwiftSyntax APIs rdar://problem/54810608
18 lines
559 B
Swift
18 lines
559 B
Swift
// RUN: %swift-syntax-test -input-source-filename %s -dump-full-tokens | %FileCheck %s
|
|
let /*leading trivia*/ `if` = 3
|
|
print(/*leading trivia*/ `if` )
|
|
|
|
// CHECK-LABEL: 2:24
|
|
// CHECK-NEXT:(Token identifier
|
|
// CHECK-NEXT: (trivia blockComment /*leading trivia*/)
|
|
// CHECK-NEXT: (trivia space 1)
|
|
// CHECK-NEXT: (text="`if`")
|
|
// CHECK-NEXT: (trivia space 1))
|
|
|
|
// CHECK-LABEL: 3:26
|
|
// CHECK-NEXT:(Token identifier
|
|
// CHECK-NEXT: (trivia blockComment /*leading trivia*/)
|
|
// CHECK-NEXT: (trivia space 1)
|
|
// CHECK-NEXT: (text="`if`")
|
|
// CHECK-NEXT: (trivia space 1))
|