File tree 2 files changed +25
-3
lines changed
2 files changed +25
-3
lines changed Original file line number Diff line number Diff line change @@ -124,7 +124,7 @@ contexts:
124
124
- match : \b(crate|extern|use|where)\b
125
125
scope : keyword.other.rust
126
126
127
- - match : \b(break|else|for|if|loop|match|while|continue)\b
127
+ - match : \b(break|else|for|if|loop|match|while|continue|yield )\b
128
128
scope : keyword.control.rust
129
129
130
130
- match : \breturn\b
@@ -298,6 +298,13 @@ contexts:
298
298
scope : support.type.rust
299
299
300
300
return-type :
301
+ - match : ' \bimpl\b'
302
+ scope : storage.type.impl.rust
303
+ push :
304
+ - include : comments
305
+ - include : impl-generic
306
+ - match : ' (?=\S)'
307
+ pop : true
301
308
- match : ' ->'
302
309
scope : punctuation.separator.rust
303
310
push :
@@ -417,7 +424,7 @@ contexts:
417
424
- match : ' {{identifier}}'
418
425
- match : ' :|,'
419
426
scope : punctuation.separator.rust
420
- - match : ' \+|\bas\b'
427
+ - match : ' \+|\bas\b|= '
421
428
scope : keyword.operator.rust
422
429
- match : ' \S'
423
430
scope : invalid.illegal.rust
Original file line number Diff line number Diff line change 1
- // SYNTAX TEST "Packages/sublime-rust /RustEnhanced.sublime-syntax"
1
+ // SYNTAX TEST "Packages/Rust Enhanced /RustEnhanced.sublime-syntax"
2
2
3
3
// Line comments
4
4
// <- comment.line.double-slash
@@ -1051,3 +1051,18 @@ impl<T> From<AsRef<T>> for CliError<T> { }
1051
1051
//^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ meta.impl
1052
1052
// ^^^^^^^^ entity.name.impl
1053
1053
// ^^^ meta.generic
1054
+
1055
+ fn legal_dates_iter( ) -> Box <Iterator <Item = Date <UTC >>> {
1056
+ // ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ meta.function.return-type meta.generic
1057
+ // ^ keyword.operator
1058
+ unimplemented!( )
1059
+ }
1060
+
1061
+ fn numbers( ) -> impl Iterator <Item = u64 > {
1062
+ // ^^^^^^^^^^^^^^^^^^^^^^^^^ meta.function.return-type
1063
+ // ^^^^ meta.function.return-type storage.type.impl
1064
+ // ^^^^^^^^ meta.function.return-type support.type
1065
+ // ^^^^^^^^^^^^ meta.function.return-type meta.generic
1066
+ Generator ( move || for a in ( 0 ..10 ) { yield a; } } )
1067
+ // ^^^^^ keyword.control
1068
+ }
You can’t perform that action at this time.
0 commit comments