diff --git a/library/alloc/tests/vec.rs b/library/alloc/tests/vec.rs index 53b0d0a2718..5f7a9399453 100644 --- a/library/alloc/tests/vec.rs +++ b/library/alloc/tests/vec.rs @@ -1511,6 +1511,9 @@ fn test_stable_pointers() { // Test that, if we reserved enough space, adding and removing elements does not // invalidate references into the vector (such as `v0`). This test also // runs in Miri, which would detect such problems. + // Note that this test does *not* constitute a stable guarantee that all these functions do not + // reallocate! Only what is explicitly documented at + // is stably guaranteed. let mut v = Vec::with_capacity(128); v.push(13);