File tree Expand file tree Collapse file tree 2 files changed +48
-121
lines changed Expand file tree Collapse file tree 2 files changed +48
-121
lines changed Original file line number Diff line number Diff line change 2
2
(comment) @comment
3
3
4
4
; Strings
5
- (string) @string
6
- (encapsed_string) @string
5
+ (string_content) @string
7
6
8
7
; Names (covers function names, class names, etc.)
9
- (name) @identifier
10
-
8
+ ; (name) @identifier
9
+ (class_declaration
10
+ name: (name) @identifier )
11
+ (const_declaration
12
+ (const_element (name) @identifier ))
13
+ (namespace_definition
14
+ (namespace_name (name) @identifier ))
15
+ (property_element
16
+ (variable_name (name) @identifier ))
17
+ (method_declaration
18
+ name: (name) @identifier )
19
+ (assignment_expression
20
+ left: (variable_name (name) @identifier ))
21
+ (function_definition
22
+ name: (name) @identifier )
23
+ (simple_parameter
24
+ (variable_name (name) @identifier ))
25
+ (catch_clause
26
+ (variable_name (name) @identifier ))
11
27
; Variable names - simplified with no nested structure
12
28
; (variable_name) @identifier
Original file line number Diff line number Diff line change @@ -71,18 +71,11 @@ $userDetails = $userr->getUserDeetails();
71
71
) ,
72
72
WordLocation :: new(
73
73
"Servicce" . to_string( ) ,
74
- vec![
75
- TextRange {
76
- start_char: 10 ,
77
- end_char: 18 ,
78
- line: 7 ,
79
- } ,
80
- TextRange {
81
- start_char: 17 ,
82
- end_char: 25 ,
83
- line: 48 ,
84
- } ,
85
- ] ,
74
+ vec![ TextRange {
75
+ start_char: 10 ,
76
+ end_char: 18 ,
77
+ line: 7 ,
78
+ } ] ,
86
79
) ,
87
80
WordLocation :: new(
88
81
"ACTIVVE" . to_string( ) ,
@@ -105,21 +98,6 @@ $userDetails = $userr->getUserDeetails();
105
98
end_char: 40 ,
106
99
line: 16 ,
107
100
} ,
108
- TextRange {
109
- start_char: 19 ,
110
- end_char: 22 ,
111
- line: 17 ,
112
- } ,
113
- TextRange {
114
- start_char: 30 ,
115
- end_char: 33 ,
116
- line: 17 ,
117
- } ,
118
- TextRange {
119
- start_char: 65 ,
120
- end_char: 68 ,
121
- line: 23 ,
122
- } ,
123
101
] ,
124
102
) ,
125
103
WordLocation :: new(
@@ -135,32 +113,15 @@ $userDetails = $userr->getUserDeetails();
135
113
end_char: 52 ,
136
114
line: 16 ,
137
115
} ,
138
- TextRange {
139
- start_char: 15 ,
140
- end_char: 24 ,
141
- line: 18 ,
142
- } ,
143
- TextRange {
144
- start_char: 28 ,
145
- end_char: 37 ,
146
- line: 18 ,
147
- } ,
148
116
] ,
149
117
) ,
150
118
WordLocation :: new(
151
119
"Deetails" . to_string( ) ,
152
- vec![
153
- TextRange {
154
- start_char: 27 ,
155
- end_char: 35 ,
156
- line: 22 ,
157
- } ,
158
- TextRange {
159
- start_char: 30 ,
160
- end_char: 38 ,
161
- line: 49 ,
162
- } ,
163
- ] ,
120
+ vec![ TextRange {
121
+ start_char: 27 ,
122
+ end_char: 35 ,
123
+ line: 22 ,
124
+ } ] ,
164
125
) ,
165
126
WordLocation :: new(
166
127
"querry" . to_string( ) ,
@@ -188,63 +149,27 @@ $userDetails = $userr->getUserDeetails();
188
149
) ,
189
150
WordLocation :: new(
190
151
"amountt" . to_string( ) ,
191
- vec![
192
- TextRange {
193
- start_char: 26 ,
194
- end_char: 33 ,
195
- line: 34 ,
196
- } ,
197
- TextRange {
198
- start_char: 48 ,
199
- end_char: 55 ,
200
- line: 39 ,
201
- } ,
202
- ] ,
152
+ vec![ TextRange {
153
+ start_char: 26 ,
154
+ end_char: 33 ,
155
+ line: 34 ,
156
+ } ] ,
203
157
) ,
204
158
WordLocation :: new(
205
159
"symboll" . to_string( ) ,
206
- vec![
207
- TextRange {
208
- start_char: 5 ,
209
- end_char: 12 ,
210
- line: 35 ,
211
- } ,
212
- TextRange {
213
- start_char: 23 ,
214
- end_char: 30 ,
215
- line: 39 ,
216
- } ,
217
- ] ,
160
+ vec![ TextRange {
161
+ start_char: 5 ,
162
+ end_char: 12 ,
163
+ line: 35 ,
164
+ } ] ,
218
165
) ,
219
166
WordLocation :: new(
220
167
"formattted" . to_string( ) ,
221
- vec![
222
- TextRange {
223
- start_char: 9 ,
224
- end_char: 19 ,
225
- line: 39 ,
226
- } ,
227
- TextRange {
228
- start_char: 12 ,
229
- end_char: 22 ,
230
- line: 44 ,
231
- } ,
232
- ] ,
233
- ) ,
234
- WordLocation :: new(
235
- "Excepton" . to_string( ) ,
236
- vec![
237
- TextRange {
238
- start_char: 23 ,
239
- end_char: 31 ,
240
- line: 26 ,
241
- } ,
242
- TextRange {
243
- start_char: 13 ,
244
- end_char: 21 ,
245
- line: 40 ,
246
- } ,
247
- ] ,
168
+ vec![ TextRange {
169
+ start_char: 9 ,
170
+ end_char: 19 ,
171
+ line: 39 ,
172
+ } ] ,
248
173
) ,
249
174
WordLocation :: new(
250
175
"errr" . to_string( ) ,
@@ -256,30 +181,16 @@ $userDetails = $userr->getUserDeetails();
256
181
) ,
257
182
WordLocation :: new(
258
183
"userr" . to_string( ) ,
259
- vec![
260
- TextRange {
261
- start_char: 1 ,
262
- end_char: 6 ,
263
- line: 48 ,
264
- } ,
265
- TextRange {
266
- start_char: 16 ,
267
- end_char: 21 ,
268
- line: 49 ,
269
- } ,
270
- ] ,
271
- ) ,
272
- WordLocation :: new(
273
- "dbb" . to_string( ) ,
274
184
vec![ TextRange {
275
- start_char: 32 ,
276
- end_char: 35 ,
185
+ start_char: 1 ,
186
+ end_char: 6 ,
277
187
line: 48 ,
278
188
} ] ,
279
189
) ,
280
190
] ;
281
191
282
192
let not_expected = [
193
+ "Excepton" ,
283
194
"php" ,
284
195
"namespace" ,
285
196
"class" ,
You can’t perform that action at this time.
0 commit comments