mirror of
https://github.com/apple/swift.git
synced 2025-12-14 20:36:38 +01:00
[libSyntax] Remove the C++ SyntaxClassifier
The recommended way forward is to use the SyntaxClassifier on the Swift side. By removing the C++ SyntaxClassifier, we can also eliminate the -force-libsyntax-based-processing option that was used to bootstrap incremental parsing and would generate the syntax map from a syntax tree.
This commit is contained in:
@@ -1,7 +1,5 @@
|
||||
// RUN: %sourcekitd-test -req=open -print-raw-response %S/Inputs/syntaxmap-edit-block-comment.swift == -req=edit -print-raw-response %S/Inputs/syntaxmap-edit-block-comment.swift -pos=4:2 -replace=" " -length=1 == -req=edit -print-raw-response %S/Inputs/syntaxmap-edit-block-comment.swift -pos=4:2 -replace="/" -length=1 == -req=edit -print-raw-response %S/Inputs/syntaxmap-edit-block-comment.swift -pos=1:1 -replace="//" -length=2 | %sed_clean > %t.response
|
||||
// RUN: %FileCheck -input-file=%t.response %s --check-prefixes CHECK,CHECK-OLD
|
||||
// RUN: %sourcekitd-test -req=open -print-raw-response %S/Inputs/syntaxmap-edit-block-comment.swift -force-libsyntax-based-processing == -req=edit -print-raw-response %S/Inputs/syntaxmap-edit-block-comment.swift -pos=4:2 -replace=" " -length=1 -force-libsyntax-based-processing == -req=edit -print-raw-response %S/Inputs/syntaxmap-edit-block-comment.swift -pos=4:2 -replace="/" -length=1 -force-libsyntax-based-processing == -req=edit -print-raw-response %S/Inputs/syntaxmap-edit-block-comment.swift -pos=1:1 -replace="//" -length=2 -force-libsyntax-based-processing | %sed_clean > %t.libSyntax.response
|
||||
// RUN: %FileCheck -input-file=%t.libSyntax.response %s --check-prefixes CHECK,CHECK-NEW
|
||||
// RUN: %FileCheck -input-file=%t.response %s
|
||||
|
||||
// Initial state
|
||||
|
||||
@@ -89,14 +87,12 @@
|
||||
|
||||
// CHECK: {{^}}{
|
||||
// CHECK-NEXT: key.offset: 0,
|
||||
// CHECK-OLD-NEXT: key.length: 3,
|
||||
// CHECK-NEW-NEXT: key.length: 2,
|
||||
// CHECK-NEXT: key.length: 3,
|
||||
// CHECK-NEXT: key.diagnostic_stage: source.diagnostic.stage.swift.parse,
|
||||
// CHECK-NEXT: key.syntaxmap: [
|
||||
// CHECK-NEXT: {
|
||||
// CHECK-NEXT: key.kind: source.lang.swift.syntaxtype.comment,
|
||||
// CHECK-NEXT: key.offset: 0,
|
||||
// CHECK-OLD-NEXT: key.length: 3
|
||||
// CHECK-NEW-NEXT: key.length: 2
|
||||
// CHECK-NEXT: key.length: 3
|
||||
// CHECK-NEXT: }
|
||||
// CHECK-NEXT: ],
|
||||
|
||||
Reference in New Issue
Block a user