rust/compiler/rustc_parse/src
bors 6d05f12170 Auto merge of #129346 - nnethercote:fix-double-handling-in-collect_tokens, r=petrochenkov
Fix double handling in `collect_tokens`

Double handling of AST nodes can occur in `collect_tokens`. This is when an inner call to `collect_tokens` produces an AST node, and then an outer call to `collect_tokens` produces the same AST node. This can happen in a few places, e.g. expression statements where the statement delegates `HasTokens` and `HasAttrs` to the expression. It will also happen more after #124141.

This PR fixes some double handling cases that cause problems, including #129166.

r? `@petrochenkov`
2024-09-08 05:35:23 +00:00
..
lexer Add some more tests 2024-09-06 10:32:48 -04:00
parser Auto merge of #129346 - nnethercote:fix-double-handling-in-collect_tokens, r=petrochenkov 2024-09-08 05:35:23 +00:00
errors.rs Add warn(unreachable_pub) to rustc_parser. 2024-08-29 20:13:06 +10:00
lib.rs Add warn(unreachable_pub) to rustc_parser. 2024-08-29 20:13:06 +10:00
validate_attr.rs Stabilize unsafe_attributes 2024-08-07 03:12:13 -05:00