File tree Expand file tree Collapse file tree 1 file changed +0
-16
lines changed
packages/cursorless-engine/src/languages/TreeSitterQuery Expand file tree Collapse file tree 1 file changed +0
-16
lines changed Original file line number Diff line number Diff line change @@ -62,21 +62,6 @@ class HasMultipleChildrenOfType extends QueryPredicateOperator<HasMultipleChildr
62
62
}
63
63
}
64
64
65
- /**
66
- * A predicate operator that returns true if the nodes text matched the regular expression
67
- */
68
- class Match extends QueryPredicateOperator < Match > {
69
- name = "match?" as const ;
70
- schema = z . tuple ( [ q . node , q . string ] ) ;
71
-
72
- run ( nodeInfo : MutableQueryCapture , pattern : string ) {
73
- const { document, range } = nodeInfo ;
74
- const regex = new RegExp ( pattern , "ds" ) ;
75
- const text = document . getText ( range ) ;
76
- return regex . test ( text ) ;
77
- }
78
- }
79
-
80
65
class ChildRange extends QueryPredicateOperator < ChildRange > {
81
66
name = "child-range!" as const ;
82
67
schema = z . union ( [
@@ -292,5 +277,4 @@ export const queryPredicateOperators = [
292
277
new InsertionDelimiter ( ) ,
293
278
new SingleOrMultilineDelimiter ( ) ,
294
279
new HasMultipleChildrenOfType ( ) ,
295
- new Match ( ) ,
296
280
] ;
You can’t perform that action at this time.
0 commit comments