From 2db2327aafe2de16cb2757c4efe779b644099a28 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?St=C3=A9phane=20Campinas?= Date: Thu, 16 Aug 2018 20:00:49 +0200 Subject: [PATCH] fix verbose output --- src/formatting.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/formatting.rs b/src/formatting.rs index d29c9398174..a695d3363a6 100644 --- a/src/formatting.rs +++ b/src/formatting.rs @@ -87,13 +87,13 @@ fn format_project( if (config.skip_children() && path != main_file) || config.ignore().skip_file(&path) { continue; } - should_emit_verbose(!input_is_stdin, config, || println!("Formatting {}", path)); + should_emit_verbose(input_is_stdin, config, || println!("Formatting {}", path)); let is_root = path == main_file; context.format_file(path, module, is_root)?; } timer = timer.done_formatting(); - should_emit_verbose(!input_is_stdin, config, || { + should_emit_verbose(input_is_stdin, config, || { println!( "Spent {0:.3} secs in the parsing phase, and {1:.3} secs in the formatting phase", timer.get_parse_time(), @@ -611,7 +611,7 @@ fn parse_crate( // Note that if you see this message and want more information, // then run the `parse_crate_mod` function above without // `catch_unwind` so rustfmt panics and you can get a backtrace. - should_emit_verbose(!input_is_stdin, config, || { + should_emit_verbose(input_is_stdin, config, || { println!("The Rust parser panicked") }); }