4d386d9f04
It is possible to have more than one valid suggestion, which when applied together via rustfix causes the code to no longer compile. This is a temporary workaround; the real long term solution to these issues is to solve <https://github.com/rust-lang/rust/issues/53934>.
19 lines
651 B
Plaintext
19 lines
651 B
Plaintext
warning: ambiguous wide pointer comparison, the comparison includes metadata which may not be expected
|
|
--> $DIR/ambiguous_wide_pointer_comparisons_suggestions.rs:8:13
|
|
|
|
|
LL | let _ = a == b;
|
|
| ^^^^^^
|
|
|
|
|
= note: `#[warn(ambiguous_wide_pointer_comparisons)]` on by default
|
|
help: use `std::ptr::addr_eq` or untyped pointers to only compare their addresses
|
|
|
|
|
LL | let _ = std::ptr::addr_eq(a, b);
|
|
| ++++++++++++++++++ ~ +
|
|
help: use explicit `std::ptr::eq` method to compare metadata and addresses
|
|
|
|
|
LL | let _ = std::ptr::eq(a, b);
|
|
| +++++++++++++ ~ +
|
|
|
|
warning: 1 warning emitted
|
|
|