mirror of
https://github.com/rust-lang/rust.git
synced 2025-11-12 22:07:29 +00:00
Use `create_snapshot_for_diagnostic` instead of `clone` for `Parser`
Use [`create_snapshot_for_diagnostic`](cd11905716/compiler/rustc_parse/src/parser/diagnostics.rs (L214-L223)) I implemented in https://github.com/rust-lang/rust/pull/94731 instead of `clone` to avoid duplicate unclosed delims errors being emitted when the `Parser` is dropped. I missed this one in #95068.