Add support for deserializing &strs

This commit is contained in:
Erick Tryzelaar 2014-10-03 17:59:21 -07:00
parent eef1587b84
commit be825b8629

View File

@ -31,6 +31,10 @@ pub trait Visitor<D: Deserializer<E>, R, E> {
Err(d.syntax_error())
}
fn visit_str(&mut self, d: &mut D, v: &str) -> Result<R, E> {
self.visit_string(d, v.to_string())
}
fn visit_string(&mut self, d: &mut D, _v: String) -> Result<R, E> {
Err(d.syntax_error())
}