From dab76eccdfbb6f7b4b445ad05ba4ef004c43e130 Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Sat, 12 Oct 2024 11:52:30 +0200 Subject: fix a couple clippy:complexitys double_parens filter_map_identity needless_question_mark redundant_guards --- compiler/rustc_middle/src/mir/pretty.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'compiler/rustc_middle/src') diff --git a/compiler/rustc_middle/src/mir/pretty.rs b/compiler/rustc_middle/src/mir/pretty.rs index 2a3a070a6e7..faa022b50ef 100644 --- a/compiler/rustc_middle/src/mir/pretty.rs +++ b/compiler/rustc_middle/src/mir/pretty.rs @@ -277,9 +277,9 @@ pub fn create_dump_file<'tcx>( ) })?; } - Ok(fs::File::create_buffered(&file_path).map_err(|e| { + fs::File::create_buffered(&file_path).map_err(|e| { io::Error::new(e.kind(), format!("IO error creating MIR dump file: {file_path:?}; {e}")) - })?) + }) } /////////////////////////////////////////////////////////////////////////// -- cgit 1.4.1-3-g733a5