Skip to content

Commit 07ce2a3

Browse files
authored
Rollup merge of rust-lang#52946 - Ajacmac:doc-impl-from, r=GuillaumeGomez
Documented impl From on line 367 of libserialize/json.rs This is for the impl From mentioned in rust-lang#51430 assigned to @skade . Hopefully I didn't miss anything/get anything wrong. I looked over another PR for another part of this same issue to see what the proper formatting was, etc. Thanks!
2 parents 5050349 + 352b2e7 commit 07ce2a3

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

src/libserialize/json.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -365,6 +365,9 @@ impl std::error::Error for EncoderError {
365365
}
366366

367367
impl From<fmt::Error> for EncoderError {
368+
/// Converts a [`fmt::Error`] into `EncoderError`
369+
///
370+
/// This conversion does not allocate memory.
368371
fn from(err: fmt::Error) -> EncoderError { EncoderError::FmtError(err) }
369372
}
370373

0 commit comments

Comments
 (0)