We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 47551b1 commit 1fd64cfCopy full SHA for 1fd64cf
src/libcore/char/methods.rs
@@ -341,12 +341,12 @@ impl char {
341
///
342
/// // both can be represented as three bytes
343
/// assert_eq!(3, eastern.len_utf8());
344
- /// assert_eq!(3, capitol.len_utf8());
+ /// assert_eq!(3, capital.len_utf8());
345
346
/// // as a &str, these two are encoded in UTF-8
347
/// let tokyo = "東京";
348
349
- /// let len = eastern.len_utf8() + capitol.len_utf8();
+ /// let len = eastern.len_utf8() + capital.len_utf8();
350
351
/// // we can see that they take six bytes total...
352
/// assert_eq!(6, tokyo.len());
0 commit comments