mirror of
https://github.com/rust-lang/rust-clippy
synced 2024-11-30 08:30:45 +00:00
68 lines
2.1 KiB
Text
68 lines
2.1 KiB
Text
error: comparing trait object pointers compares a non-unique vtable address
|
|
--> $DIR/vtable_address_comparisons.rs:14:13
|
|
|
|
|
LL | let _ = a == b;
|
|
| ^^^^^^
|
|
|
|
|
= help: consider extracting and comparing data pointers only
|
|
= note: `-D clippy::vtable-address-comparisons` implied by `-D warnings`
|
|
= help: to override `-D warnings` add `#[allow(clippy::vtable_address_comparisons)]`
|
|
|
|
error: comparing trait object pointers compares a non-unique vtable address
|
|
--> $DIR/vtable_address_comparisons.rs:16:13
|
|
|
|
|
LL | let _ = a != b;
|
|
| ^^^^^^
|
|
|
|
|
= help: consider extracting and comparing data pointers only
|
|
|
|
error: comparing trait object pointers compares a non-unique vtable address
|
|
--> $DIR/vtable_address_comparisons.rs:18:13
|
|
|
|
|
LL | let _ = a < b;
|
|
| ^^^^^
|
|
|
|
|
= help: consider extracting and comparing data pointers only
|
|
|
|
error: comparing trait object pointers compares a non-unique vtable address
|
|
--> $DIR/vtable_address_comparisons.rs:20:13
|
|
|
|
|
LL | let _ = a <= b;
|
|
| ^^^^^^
|
|
|
|
|
= help: consider extracting and comparing data pointers only
|
|
|
|
error: comparing trait object pointers compares a non-unique vtable address
|
|
--> $DIR/vtable_address_comparisons.rs:22:13
|
|
|
|
|
LL | let _ = a > b;
|
|
| ^^^^^
|
|
|
|
|
= help: consider extracting and comparing data pointers only
|
|
|
|
error: comparing trait object pointers compares a non-unique vtable address
|
|
--> $DIR/vtable_address_comparisons.rs:24:13
|
|
|
|
|
LL | let _ = a >= b;
|
|
| ^^^^^^
|
|
|
|
|
= help: consider extracting and comparing data pointers only
|
|
|
|
error: comparing trait object pointers compares a non-unique vtable address
|
|
--> $DIR/vtable_address_comparisons.rs:26:5
|
|
|
|
|
LL | ptr::eq(a, b);
|
|
| ^^^^^^^^^^^^^
|
|
|
|
|
= help: consider extracting and comparing data pointers only
|
|
|
|
error: comparing trait object pointers compares a non-unique vtable address
|
|
--> $DIR/vtable_address_comparisons.rs:31:5
|
|
|
|
|
LL | ptr::eq(a, b);
|
|
| ^^^^^^^^^^^^^
|
|
|
|
|
= help: consider extracting and comparing data pointers only
|
|
|
|
error: aborting due to 8 previous errors
|
|
|