diff options
| author | Yuki Okushi <huyuumi.dev@gmail.com> | 2020-08-01 08:02:11 +0900 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2020-08-01 08:02:11 +0900 |
| commit | ff5ccc82eb58d76f5f4335dad4642becd1c69539 (patch) | |
| tree | eec05511d87c5145840e449145b8a47faf4772a1 | |
| parent | bb397c465c7adfe05b2927c346e9603e0a075b91 (diff) | |
| parent | 8a5654f53c434466d913e18f50e661098e0c3e9a (diff) | |
| download | rust-ff5ccc82eb58d76f5f4335dad4642becd1c69539.tar.gz rust-ff5ccc82eb58d76f5f4335dad4642becd1c69539.zip | |
Rollup merge of #74986 - matthiaskrgr:cmp_true, r=oli-obk
fix part of comparison that would always evaluate to "true", probably an oversight cc @jumbatm
| -rw-r--r-- | src/librustc_lint/builtin.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/librustc_lint/builtin.rs b/src/librustc_lint/builtin.rs index 06e7c2b6f36..e32c8fbee68 100644 --- a/src/librustc_lint/builtin.rs +++ b/src/librustc_lint/builtin.rs @@ -2209,7 +2209,7 @@ impl ClashingExternDeclarations { } (Slice(a_ty), Slice(b_ty)) => Self::structurally_same_type(cx, a_ty, b_ty, ckind), (RawPtr(a_tymut), RawPtr(b_tymut)) => { - a_tymut.mutbl == a_tymut.mutbl + a_tymut.mutbl == b_tymut.mutbl && Self::structurally_same_type(cx, &a_tymut.ty, &b_tymut.ty, ckind) } (Ref(_a_region, a_ty, a_mut), Ref(_b_region, b_ty, b_mut)) => { |
