diff options
| author | Matthias Krüger <matthias.krueger@famsik.de> | 2023-03-12 08:13:28 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2023-03-12 08:13:28 +0100 |
| commit | c9a38c3c697cb9db276178ec3690a08f599d38d4 (patch) | |
| tree | f4df6664f96dbba838a9a5739956ed1ccf1951cc | |
| parent | 738c4bf176cc2bae9d51e19b292f8f5f1ce4fd0b (diff) | |
| parent | 898d2c14e3e538056800499598b54e3d2daa5b87 (diff) | |
| download | rust-c9a38c3c697cb9db276178ec3690a08f599d38d4.tar.gz rust-c9a38c3c697cb9db276178ec3690a08f599d38d4.zip | |
Rollup merge of #109017 - klensy:dupe, r=cjgillot
remove duplicated calls to sort_string `with_forced_trimmed_paths!` was removed in https://github.com/rust-lang/rust/commit/62ba3e70a1f01d801d068b84a097e38bd82a8c6e, and this lines became dups.
| -rw-r--r-- | compiler/rustc_middle/src/ty/error.rs | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/compiler/rustc_middle/src/ty/error.rs b/compiler/rustc_middle/src/ty/error.rs index 9c171a69d06..aff6c77e039 100644 --- a/compiler/rustc_middle/src/ty/error.rs +++ b/compiler/rustc_middle/src/ty/error.rs @@ -151,12 +151,8 @@ impl<'tcx> TypeError<'tcx> { .into(), RegionsPlaceholderMismatch => "one type is more general than the other".into(), ArgumentSorts(values, _) | Sorts(values) => { - let mut expected = values.expected.sort_string(tcx); - let mut found = values.found.sort_string(tcx); - if expected == found { - expected = values.expected.sort_string(tcx); - found = values.found.sort_string(tcx); - } + let expected = values.expected.sort_string(tcx); + let found = values.found.sort_string(tcx); report_maybe_different(&expected, &found).into() } Traits(values) => { |
