Skip to content

Commit e10e0bc

Browse files
committed
Use question_mark feature in librustc_mir.
1 parent 8a9e52a commit e10e0bc

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

src/librustc_mir/pretty.rs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -77,12 +77,12 @@ pub fn dump_mir<'a, 'tcx>(tcx: TyCtxt<'a, 'tcx, 'tcx>,
7777
node_id, promotion_id, pass_name, disambiguator);
7878
file_path.push(&file_name);
7979
let _ = fs::File::create(&file_path).and_then(|mut file| {
80-
try!(writeln!(file, "// MIR for `{}`", node_path));
81-
try!(writeln!(file, "// node_id = {}", node_id));
82-
try!(writeln!(file, "// pass_name = {}", pass_name));
83-
try!(writeln!(file, "// disambiguator = {}", disambiguator));
84-
try!(writeln!(file, ""));
85-
try!(write_mir_fn(tcx, src, mir, &mut file, auxiliary));
80+
writeln!(file, "// MIR for `{}`", node_path)?;
81+
writeln!(file, "// node_id = {}", node_id)?;
82+
writeln!(file, "// pass_name = {}", pass_name)?;
83+
writeln!(file, "// disambiguator = {}", disambiguator)?;
84+
writeln!(file, "")?;
85+
write_mir_fn(tcx, src, mir, &mut file, auxiliary)?;
8686
Ok(())
8787
});
8888
}

0 commit comments

Comments
 (0)