rust/compiler/rustc_parse/src
Trevor Gross e2e0681e3a
Rollup merge of #127842 - nnethercote:rm-TrailingToken, r=petrochenkov
Remove `TrailingToken`.

It's used in `Parser::collect_tokens_trailing_token` to decide whether to capture a trailing token. But the callers actually know whether to capture a trailing token, so it's simpler for them to just pass in a bool.

Also, the `TrailingToken::Gt` case was weird, because it didn't result in a trailing token being captured. It could have been subsumed by the `TrailingToken::MaybeComma` case, and it effectively is in the new code.

r? `@petrochenkov`
2024-07-18 05:14:07 -05:00
..
lexer Use a dedicated type instead of a reference for the diagnostic context 2024-06-18 15:42:11 +00:00
parser Rollup merge of #127842 - nnethercote:rm-TrailingToken, r=petrochenkov 2024-07-18 05:14:07 -05:00
errors.rs Deny keyword lifetimes pre-expansion 2024-07-16 12:06:25 -04:00
lib.rs Use cfg_attr as a name more. 2024-07-10 15:11:57 +10:00
validate_attr.rs coverage: Tighten validation of #[coverage(off)] and #[coverage(on)] 2024-06-24 20:15:01 +10:00