@@ -1309,7 +1309,7 @@ impl<'a> Parser<'a> {
1309
1309
1310
1310
/// Assuming we have just parsed `.`, continue parsing into an expression.
1311
1311
fn parse_dot_suffix ( & mut self , self_arg : P < Expr > , lo : Span ) -> PResult < ' a , P < Expr > > {
1312
- if self . token . uninterpolated_span ( ) . rust_2018 ( ) && self . eat_keyword ( kw:: Await ) {
1312
+ if self . token . uninterpolated_span ( ) . at_least_rust_2018 ( ) && self . eat_keyword ( kw:: Await ) {
1313
1313
return Ok ( self . mk_await_expr ( self_arg, lo) ) ;
1314
1314
}
1315
1315
@@ -1442,8 +1442,8 @@ impl<'a> Parser<'a> {
1442
1442
self . parse_expr_let ( )
1443
1443
} else if self . eat_keyword ( kw:: Underscore ) {
1444
1444
Ok ( self . mk_expr ( self . prev_token . span , ExprKind :: Underscore ) )
1445
- } else if self . token . uninterpolated_span ( ) . rust_2018 ( ) {
1446
- // `Span::rust_2018 ()` is somewhat expensive; don't get it repeatedly.
1445
+ } else if self . token . uninterpolated_span ( ) . at_least_rust_2018 ( ) {
1446
+ // `Span:.at_least_rust_2018 ()` is somewhat expensive; don't get it repeatedly.
1447
1447
if self . check_keyword ( kw:: Async ) {
1448
1448
if self . is_async_block ( ) {
1449
1449
// Check for `async {` and `async move {`.
@@ -2230,7 +2230,7 @@ impl<'a> Parser<'a> {
2230
2230
let movability =
2231
2231
if self . eat_keyword ( kw:: Static ) { Movability :: Static } else { Movability :: Movable } ;
2232
2232
2233
- let asyncness = if self . token . uninterpolated_span ( ) . rust_2018 ( ) {
2233
+ let asyncness = if self . token . uninterpolated_span ( ) . at_least_rust_2018 ( ) {
2234
2234
self . parse_asyncness ( Case :: Sensitive )
2235
2235
} else {
2236
2236
Async :: No
@@ -3014,7 +3014,7 @@ impl<'a> Parser<'a> {
3014
3014
fn is_try_block ( & self ) -> bool {
3015
3015
self . token . is_keyword ( kw:: Try )
3016
3016
&& self . look_ahead ( 1 , |t| * t == token:: OpenDelim ( Delimiter :: Brace ) )
3017
- && self . token . uninterpolated_span ( ) . rust_2018 ( )
3017
+ && self . token . uninterpolated_span ( ) . at_least_rust_2018 ( )
3018
3018
}
3019
3019
3020
3020
/// Parses an `async move? {...}` expression.
0 commit comments