mirror of
https://github.com/allankoechke/rust.git
synced 2026-11-30 11:05:36 +00:00
Parser: Refactor & better document `should_continue_as_assoc_expr` & `can_continue_expr_unambiguously` Whenever I stumbled across `should_continue_as_assoc_expr` I had to very slowly reread its impl because the contained `match` was written in an incredibly convoluted fashion rendering it illegible. Moreover, I always had a hard time figuring out what part of the code was recovery & what actual parsing, esp. since it does indeed save extra diagnostic info in the happy path (proactively). See commit message for details. <sub>(No LLM was or will be used by me during the entire creation process of this PR)</sub>