]> git.lizzy.rs Git - rust.git/commit
rustfmt: Make error handling more idiomatic
authorKamal Marhubi <kamal@marhubi.com>
Sat, 9 Apr 2016 20:15:36 +0000 (16:15 -0400)
committerKamal Marhubi <kamal@marhubi.com>
Sun, 10 Apr 2016 21:58:14 +0000 (17:58 -0400)
commitfe5fa874da6ce1691add81a46f9bfd0a28d39076
tree78686098b32aeb68a01f9fdc4ea6b45a9322a72d
parentb55e50f3875f5b531f8180dcab3a260ad1f351a1
rustfmt: Make error handling more idiomatic

This commit replaces the `Operation::InvalidInput` variant with
`Result`, and uses the `try!()` macro instead of explicit matching.
src/bin/rustfmt.rs