doc(serde): Document the visit_string method

Closes #184
This commit is contained in:
Erick Tryzelaar 2016-02-21 16:03:33 -08:00
parent 7adf624dee
commit 4d10eef55d

View File

@ -541,7 +541,9 @@ pub trait Visitor {
Err(Error::type_mismatch(Type::Str))
}
/// `visit_string` deserializes a `String` into a `Value`.
/// `visit_string` deserializes a `String` into a `Value`. This allows a deserializer to avoid
/// a copy if it is deserializing a string from a `String` type. By default it passes a `&str`
/// to the `visit_str` method.
#[inline]
fn visit_string<E>(&mut self, v: String) -> Result<Self::Value, E>
where E: Error,