Port try macro to new ? operator. (#3962)

* initial untry sweep

* restore try in ipc codegen, fix inference

* change a few missed try instances
This commit is contained in:
Robert Habermeier
2016-12-27 12:53:56 +01:00
committed by Arkadiy Paronyan
parent b1ef52a6d7
commit 8125b5690c
165 changed files with 1696 additions and 1696 deletions

View File

@@ -86,10 +86,9 @@ pub fn setup_log(config: &Config) -> Result<Arc<RotatingLogger>, String> {
let mut open_options = fs::OpenOptions::new();
let maybe_file = match config.file.as_ref() {
Some(f) => Some(try!(open_options
Some(f) => Some(open_options
.append(true).create(true).open(f)
.map_err(|_| format!("Cannot write to log file given: {}", f))
)),
.map_err(|_| format!("Cannot write to log file given: {}", f))?),
None => None,
};