Correct char.encode_utf16() documentation
The "A buffer that's too small" example was calling encode_utf8().
This commit is contained in:
parent
c8fc4817dc
commit
60ce31a00c
1 changed files with 1 additions and 1 deletions
|
|
@ -476,7 +476,7 @@ impl char {
|
|||
///
|
||||
/// let mut b = [0; 0];
|
||||
///
|
||||
/// let result = 'ß'.encode_utf8(&mut b);
|
||||
/// let result = 'ß'.encode_utf16(&mut b);
|
||||
///
|
||||
/// assert_eq!(result, None);
|
||||
/// ```
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue