Skip to content

Commit 1fd64cf

Browse files
author
lcolaholicl
committed
fix the same typo in doctest
1 parent 47551b1 commit 1fd64cf

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/libcore/char/methods.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -341,12 +341,12 @@ impl char {
341341
///
342342
/// // both can be represented as three bytes
343343
/// assert_eq!(3, eastern.len_utf8());
344-
/// assert_eq!(3, capitol.len_utf8());
344+
/// assert_eq!(3, capital.len_utf8());
345345
///
346346
/// // as a &str, these two are encoded in UTF-8
347347
/// let tokyo = "東京";
348348
///
349-
/// let len = eastern.len_utf8() + capitol.len_utf8();
349+
/// let len = eastern.len_utf8() + capital.len_utf8();
350350
///
351351
/// // we can see that they take six bytes total...
352352
/// assert_eq!(6, tokyo.len());

0 commit comments

Comments
 (0)