diff options
| author | bors <bors@rust-lang.org> | 2023-03-08 22:48:17 +0000 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2023-03-08 22:48:17 +0000 |
| commit | 6a179026decb823e6ad8ba1c81729528bc5d695f (patch) | |
| tree | 98f20f23dde3d9aca52c76c0a783eb374c458115 /compiler/rustc_parse/src | |
| parent | 900c3540378c8422b8087ffa3db60fa6c8abfcad (diff) | |
| parent | 7732cccd993f6caeedad7b9c24850768705179ab (diff) | |
| download | rust-6a179026decb823e6ad8ba1c81729528bc5d695f.tar.gz rust-6a179026decb823e6ad8ba1c81729528bc5d695f.zip | |
Auto merge of #108919 - matthiaskrgr:rollup-g271pm2, r=matthiaskrgr
Rollup of 8 pull requests Successful merges: - #108686 (rustdoc: include link on all.html location header) - #108846 (StableMIR: Proof-of-concept implementation + test ) - #108873 (Simplify `sort_by` calls) - #108883 (Suppress copy impl error when post-normalized type references errors) - #108884 (Tweak illegal `Copy` impl message) - #108887 (Rename `MapInPlace` as `FlatMapInPlace`.) - #108901 (fix: evaluate with wrong obligation stack) - #108903 (Move Clippy tests back to their intended directory) Failed merges: r? `@ghost` `@rustbot` modify labels: rollup
Diffstat (limited to 'compiler/rustc_parse/src')
| -rw-r--r-- | compiler/rustc_parse/src/lexer/diagnostics.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/compiler/rustc_parse/src/lexer/diagnostics.rs b/compiler/rustc_parse/src/lexer/diagnostics.rs index 27f4428d306..c4b9fdc81c5 100644 --- a/compiler/rustc_parse/src/lexer/diagnostics.rs +++ b/compiler/rustc_parse/src/lexer/diagnostics.rs @@ -71,7 +71,7 @@ pub fn report_suspicious_mismatch_block( .collect(); // sort by `lo`, so the large block spans in the front - matched_spans.sort_by(|a, b| a.0.lo().cmp(&b.0.lo())); + matched_spans.sort_by_key(|(span, _)| span.lo()); // We use larger block whose identation is well to cover those inner mismatched blocks // O(N^2) here, but we are on error reporting path, so it is fine |
