Update note to include recommendation to use .as_slice()

This commit is contained in:
JessRudder 2016-08-12 10:39:40 -04:00
parent 91a2c25e2e
commit 758aff7883

View File

@ -387,7 +387,8 @@ mod prim_slice { }
/// [`len()`]: #method.len
///
/// Note: This example shows the internals of `&str`. `unsafe` should not be
/// used to get a string slice under normal circumstances.
/// used to get a string slice under normal circumstances. Use `.as_slice()`
/// instead.
mod prim_str { }
#[doc(primitive = "tuple")]