File tree 2 files changed +18
-1
lines changed
2 files changed +18
-1
lines changed Original file line number Diff line number Diff line change @@ -367,9 +367,10 @@ contexts:
367
367
# scope as soon as we hit something that it not a
368
368
# valid part so the whole rest of the document isn't
369
369
# highlighted using the params scope
370
+ - include : comments
370
371
- match : ' (?=\()'
371
372
push : group
372
- - match : ' (?=[};)\]\n ])'
373
+ - match : ' (?=[};)\]])'
373
374
pop : true
374
375
- match : ' \|'
375
376
scope : punctuation.definition.parameters.end.rust
Original file line number Diff line number Diff line change @@ -1352,3 +1352,19 @@ impl<A> Thing for &'a mut A {}
1352
1352
// ^^ meta.impl storage.modifier.lifetime
1353
1353
// ^^^ meta.impl storage.modifier
1354
1354
// ^ meta.impl entity.name.impl
1355
+
1356
+ fn lambdas( ) {
1357
+ let c = |foo,
1358
+ // ^ meta.function.closure meta.function.parameters punctuation.definition.parameters.begin
1359
+ // ^^^ meta.function.parameters variable.parameter
1360
+ bar| { } ;
1361
+ // ^^^ meta.function.parameters variable.parameter
1362
+ // ^ meta.function.closure meta.function.parameters punctuation.definition.parameters.end
1363
+ let c = |foo, // weird, but should work
1364
+ // ^ meta.function.closure meta.function.parameters punctuation.definition.parameters.begin
1365
+ // ^^^ meta.function.parameters variable.parameter
1366
+ // ^^^^^^^^^^^^^^^^^^^^^^^^^ comment.line
1367
+ bar| { } ;
1368
+ // ^^^ meta.function.parameters variable.parameter
1369
+ // ^ meta.function.closure meta.function.parameters punctuation.definition.parameters.end
1370
+ }
You can’t perform that action at this time.
0 commit comments