about summary refs log tree commit diff
diff options
context:
space:
mode:
authorGeorge Bateman <george.bateman16@gmail.com>2022-01-27 22:13:01 +0000
committerGeorge Bateman <george.bateman16@gmail.com>2022-01-27 22:13:01 +0000
commit2fb617ca0f1edd42116ebe8e8175b4abb2042a9b (patch)
tree2a231be4f3ab5fba7a2a7391fd3682c54aea29bc
parent8cdb3cd94efece1e17cbd8f6edb1dc1a482779a0 (diff)
downloadrust-2fb617ca0f1edd42116ebe8e8175b4abb2042a9b.tar.gz
rust-2fb617ca0f1edd42116ebe8e8175b4abb2042a9b.zip
Clarify documentation on char::MAX
-rw-r--r--library/core/src/char/methods.rs8
1 files changed, 4 insertions, 4 deletions
diff --git a/library/core/src/char/methods.rs b/library/core/src/char/methods.rs
index 7250dca2adf..62ef1ca7885 100644
--- a/library/core/src/char/methods.rs
+++ b/library/core/src/char/methods.rs
@@ -9,11 +9,11 @@ use super::*;
 
 #[lang = "char"]
 impl char {
-    /// The highest valid code point a `char` can have.
+    /// The highest valid code point a `char` can have, 0x10FFFF.
     ///
-    /// A `char` is a [Unicode Scalar Value], which means that it is a [Code
-    /// Point], but only ones within a certain range. `MAX` is the highest valid
-    /// code point that's a valid [Unicode Scalar Value].
+    /// A [Code Point] is any value between zero and `char::MAX`, inclusive. A
+    /// `char` is a [Unicode Scalar Value], which is a Code Point that is not
+    /// in the range `0xD800..=0xDFFF`.
     ///
     /// [Unicode Scalar Value]: https://www.unicode.org/glossary/#unicode_scalar_value
     /// [Code Point]: https://www.unicode.org/glossary/#code_point