Commit 5f5ffbf3 authored by Ben Boeckel's avatar Ben Boeckel
Browse files

macros: remove a `try!()` usage for the `?` operator

parent cce72ac1
......@@ -54,7 +54,7 @@ macro_rules! enum_serialize {
impl Deserialize for $name {
fn deserialize<D: Deserializer>(deserializer: &mut D) -> ::std::result::Result<Self, D::Error> {
let val = try!(String::deserialize(deserializer));
let val = String::deserialize(deserializer)?;
match val.as_str() {
$( $str => Ok($name::$value), )*
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment