diff options
| author | Nicholas Nethercote <n.nethercote@gmail.com> | 2022-04-20 11:49:15 +1000 |
|---|---|---|
| committer | Nicholas Nethercote <n.nethercote@gmail.com> | 2022-04-20 12:26:49 +1000 |
| commit | 86723d3d468745aa5e6494a766ea9ba6cb283b3c (patch) | |
| tree | 2505a3a736683e444e57a13bb4a1c55b6f38767e /compiler/rustc_parse/src | |
| parent | 804103b0aedf38cbc1a0c0dbf37a627eb48b8902 (diff) | |
| download | rust-86723d3d468745aa5e6494a766ea9ba6cb283b3c.tar.gz rust-86723d3d468745aa5e6494a766ea9ba6cb283b3c.zip | |
Use `true` for `open_delim`/`close_delim` in one spot.
The `DelimToken` here is `NoDelim`, which means the returned delim tokens will just be ignored by `Parser::bump()`. This commit changes things so the delim tokens won't be returned.
Diffstat (limited to 'compiler/rustc_parse/src')
| -rw-r--r-- | compiler/rustc_parse/src/parser/mod.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/compiler/rustc_parse/src/parser/mod.rs b/compiler/rustc_parse/src/parser/mod.rs index 67bfb98ccd3..a337d8fae0f 100644 --- a/compiler/rustc_parse/src/parser/mod.rs +++ b/compiler/rustc_parse/src/parser/mod.rs @@ -335,7 +335,7 @@ impl TokenCursor { TokenCursorFrame::new( delim_span, token::NoDelim, - false, + true, if attr_style == AttrStyle::Inner { [TokenTree::token(token::Pound, span), TokenTree::token(token::Not, span), body] .iter() @@ -347,7 +347,7 @@ impl TokenCursor { .cloned() .collect::<TokenStream>() }, - false, + true, ), )); |
