Skip to content

Commit d9c13cd

Browse files
committed
Auto merge of #113287 - RalfJung:miri-test-libstd, r=JohnTitor
enable test_join test in Miri Miri for quite a while now has a hack to support self-referential generators: non-`Unique` mutable references are exempt from aliasing conditions. So we can run this test now. (It passes.) Also extend a comment in a Vec test, while I am at it.
2 parents 5dac6b3 + e1338cc commit d9c13cd

File tree

2 files changed

+1
-1
lines changed

2 files changed

+1
-1
lines changed

library/alloc/tests/vec.rs

+1
Original file line numberDiff line numberDiff line change
@@ -1906,6 +1906,7 @@ fn test_stable_pointers() {
19061906
assert_eq!(*v0, 13);
19071907

19081908
// Smoke test that would fire even outside Miri if an actual relocation happened.
1909+
// Also ensures the pointer is still writeable after all this.
19091910
*v0 -= 13;
19101911
assert_eq!(v[0], 0);
19111912
}

library/core/tests/future.rs

-1
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,6 @@ fn poll_n(val: usize, num: usize) -> PollN {
3030
}
3131

3232
#[test]
33-
#[cfg_attr(miri, ignore)] // self-referential generators do not work with Miri's aliasing checks
3433
fn test_join() {
3534
block_on(async move {
3635
let x = join!(async { 0 }).await;

0 commit comments

Comments
 (0)