We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 6070d3e commit 5344b07Copy full SHA for 5344b07
src/libstd/ffi/c_str.rs
@@ -875,6 +875,8 @@ impl CStr {
875
/// `ptr`.
876
/// * There is no guarantee that the memory pointed to by `ptr` contains a
877
/// valid nul terminator byte at the end of the string.
878
+ /// * It is not guaranteed that the memory pointed by `ptr` won't change
879
+ /// before the `CStr` has been destroyed.
880
///
881
/// > **Note**: This operation is intended to be a 0-cost cast but it is
882
/// > currently implemented with an up-front calculation of the length of
0 commit comments