Update note to include recommendation to use .as_slice()
This commit is contained in:
parent
91a2c25e2e
commit
758aff7883
@ -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")]
|
||||
|
Loading…
Reference in New Issue
Block a user