Skip to content

Commit 96282e1

Browse files
committed
Add doc for impl From for Error
1 parent 6bf6d50 commit 96282e1

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

src/libstd/io/error.rs

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -212,6 +212,12 @@ impl ErrorKind {
212212
/// the heap (for normal construction via Error::new) is too costly.
213213
#[stable(feature = "io_error_from_errorkind", since = "1.14.0")]
214214
impl From<ErrorKind> for Error {
215+
/// Converts a [`ErrorKind`] into a [`Error`].
216+
///
217+
/// This conversion allocates a new error with simple repr.
218+
///
219+
/// [`ErrorKind`]: enum.ErrorKind.html
220+
/// [`Error`]: struct.Error.html
215221
#[inline]
216222
fn from(kind: ErrorKind) -> Error {
217223
Error {

0 commit comments

Comments
 (0)