about summary refs log tree commit diff
diff options
context:
space:
mode:
authorSimon Heath <icefoxen@gmail.com>2019-01-26 16:46:15 -0500
committerSimon Heath <icefoxen@gmail.com>2019-01-26 16:46:15 -0500
commitb4d3c87ebc32ed4b96dc64cc9b45758e356df17a (patch)
tree85195b08be89ce1b31b22ecdfda3b72e63d5ef76
parent20c2cba61dc83e612d25ed496025171caa3db30f (diff)
downloadrust-b4d3c87ebc32ed4b96dc64cc9b45758e356df17a.tar.gz
rust-b4d3c87ebc32ed4b96dc64cc9b45758e356df17a.zip
Tiny improvement to docs for `core::convert`.
This is not really significant, accept or reject as you wish.  I
just want to make sure I understand how the PR process works and
I'm doing it right before doing a bigger one for #33417.
-rw-r--r--src/libcore/convert.rs5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/libcore/convert.rs b/src/libcore/convert.rs
index 203be541e49..d4a1d15e4e7 100644
--- a/src/libcore/convert.rs
+++ b/src/libcore/convert.rs
@@ -17,7 +17,10 @@
 //! [`TryFrom<T>`][`TryFrom`] rather than [`Into<U>`][`Into`] or [`TryInto<U>`][`TryInto`],
 //! as [`From`] and [`TryFrom`] provide greater flexibility and offer
 //! equivalent [`Into`] or [`TryInto`] implementations for free, thanks to a
-//! blanket implementation in the standard library.
+//! blanket implementation in the standard library.  However, there are some cases
+//! where this is not possible, such as creating conversions into a type defined
+//! outside your library, so implementing [`Into`] instead of [`From`] is
+//! sometimes necessary.
 //!
 //! # Generic Implementations
 //!