Skip to content

Commit 83dc76e

Browse files
Update weirdly failing ui tests
1 parent a9ebf9f commit 83dc76e

File tree

6 files changed

+15
-9
lines changed

6 files changed

+15
-9
lines changed

tests/ui/codegen/equal-pointers-unequal/as-cast/inline2.rs

+3-2
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,8 @@ fn main() {
2424
&v as *const _ as usize
2525
};
2626
assert_eq!(a.to_string(), b.to_string());
27-
assert_eq!(format!("{}", a == b), "true");
28-
assert_eq!(format!("{}", cmp_in(a, b)), "true");
27+
// Changed after https://github.com/rust-lang/rust/pull/136264
28+
assert_eq!(format!("{}", a != b), "true");
29+
assert_eq!(format!("{}", cmp_in(a, b)), "false");
2930
assert_eq!(format!("{}", cmp(a, b)), "true");
3031
}

tests/ui/codegen/equal-pointers-unequal/as-cast/zero.rs

+2-1
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,7 @@ fn main() {
2323
// But it looks like zero...
2424
assert_eq!(i.to_string(), "0");
2525
// ...and now it *is* zero?
26-
assert_eq!(i, 0);
26+
// Not anymore: https://github.com/rust-lang/rust/pull/136264
27+
assert_ne!(i, 0);
2728
// So `a` and `b` are equal after all?
2829
}

tests/ui/codegen/equal-pointers-unequal/exposed-provenance/inline2.rs

+3-2
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,8 @@ fn main() {
2626
ptr::from_ref(&v).expose_provenance()
2727
};
2828
assert_eq!(a.to_string(), b.to_string());
29-
assert_eq!(format!("{}", a == b), "true");
30-
assert_eq!(format!("{}", cmp_in(a, b)), "true");
29+
// Changed after https://github.com/rust-lang/rust/pull/136264
30+
assert_eq!(format!("{}", a != b), "true");
31+
assert_eq!(format!("{}", cmp_in(a, b)), "false");
3132
assert_eq!(format!("{}", cmp(a, b)), "true");
3233
}

tests/ui/codegen/equal-pointers-unequal/exposed-provenance/zero.rs

+2-1
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@ fn main() {
2525
// But it looks like zero...
2626
assert_eq!(i.to_string(), "0");
2727
// ...and now it *is* zero?
28-
assert_eq!(i, 0);
28+
// Not anymore since https://github.com/rust-lang/rust/pull/136264
29+
assert_ne!(i, 0);
2930
// So `a` and `b` are equal after all?
3031
}

tests/ui/codegen/equal-pointers-unequal/strict-provenance/inline2.rs

+3-2
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,8 @@ fn main() {
2626
ptr::from_ref(&v).addr()
2727
};
2828
assert_eq!(a.to_string(), b.to_string());
29-
assert_eq!(format!("{}", a == b), "true");
30-
assert_eq!(format!("{}", cmp_in(a, b)), "true");
29+
// Changed after https://github.com/rust-lang/rust/pull/136264
30+
assert_eq!(format!("{}", a != b), "true");
31+
assert_eq!(format!("{}", cmp_in(a, b)), "false");
3132
assert_eq!(format!("{}", cmp(a, b)), "true");
3233
}

tests/ui/codegen/equal-pointers-unequal/strict-provenance/zero.rs

+2-1
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@ fn main() {
2525
// But it looks like zero...
2626
assert_eq!(i.to_string(), "0");
2727
// ...and now it *is* zero?
28-
assert_eq!(i, 0);
28+
// Not anymore since https://github.com/rust-lang/rust/pull/136264
29+
assert_ne!(i, 0);
2930
// So `a` and `b` are equal after all?
3031
}

0 commit comments

Comments
 (0)