Parse try as a keyword only in edition 2018 and up

This commit is contained in:
Lukas Wirth 2024-07-19 15:26:50 +02:00
parent 713c47f25b
commit d235d09bf9
8 changed files with 24 additions and 42 deletions

View file

@ -1,5 +1,7 @@
SOURCE_FILE
FN
COMMENT "// 2015"
WHITESPACE "\n"
FN_KW "fn"
WHITESPACE " "
NAME

View file

@ -1 +1,2 @@
// 2015
fn foo() { try!(Ok(())); }

View file

@ -1,5 +1,7 @@
SOURCE_FILE
MACRO_RULES
COMMENT "// 2015"
WHITESPACE "\n"
MACRO_RULES_KW "macro_rules"
BANG "!"
WHITESPACE " "

View file

@ -1 +1,2 @@
// 2015
macro_rules! try { () => {} }