@@ -1309,7 +1309,7 @@ impl<'a> Parser<'a> {
13091309
13101310 /// Assuming we have just parsed `.`, continue parsing into an expression.
13111311 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 ) {
13131313 return Ok ( self . mk_await_expr ( self_arg, lo) ) ;
13141314 }
13151315
@@ -1442,8 +1442,8 @@ impl<'a> Parser<'a> {
14421442 self . parse_expr_let ( )
14431443 } else if self . eat_keyword ( kw:: Underscore ) {
14441444 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.
14471447 if self . check_keyword ( kw:: Async ) {
14481448 if self . is_async_block ( ) {
14491449 // Check for `async {` and `async move {`.
@@ -2230,7 +2230,7 @@ impl<'a> Parser<'a> {
22302230 let movability =
22312231 if self . eat_keyword ( kw:: Static ) { Movability :: Static } else { Movability :: Movable } ;
22322232
2233- let asyncness = if self . token . uninterpolated_span ( ) . rust_2018 ( ) {
2233+ let asyncness = if self . token . uninterpolated_span ( ) . at_least_rust_2018 ( ) {
22342234 self . parse_asyncness ( Case :: Sensitive )
22352235 } else {
22362236 Async :: No
@@ -3014,7 +3014,7 @@ impl<'a> Parser<'a> {
30143014 fn is_try_block ( & self ) -> bool {
30153015 self . token . is_keyword ( kw:: Try )
30163016 && 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 ( )
30183018 }
30193019
30203020 /// Parses an `async move? {...}` expression.
0 commit comments