Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion src/cli/rustup_mode.rs
Original file line number Diff line number Diff line change
Expand Up @@ -588,7 +588,8 @@ pub async fn main(
}

let Some(subcmd) = matches.subcmd else {
eprintln!("{}", Rustup::command().render_long_help());
let help = Rustup::command().render_long_help();
writeln!(process.stderr().lock(), "{help}")?;
return Ok(utils::ExitCode(1));
};

Expand Down
1 change: 1 addition & 0 deletions src/diskio/threaded.rs
Original file line number Diff line number Diff line change
Expand Up @@ -268,6 +268,7 @@ impl<'a> Executor for Threaded<'a> {
prev_files as u64,
));
}
#[allow(clippy::print_stderr)]
if prev_files > 50 {
eprintln!("{prev_files} deferred IO operations");
}
Expand Down
5 changes: 5 additions & 0 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,11 @@
clippy::result_large_err, // 288 bytes is our 'large' variant today, which is unlikely to be a performance problem
clippy::arc_with_non_send_sync, // will get resolved as we move further into async
)]
#![cfg_attr(not(test), warn(
// We use the logging system instead of printing directly.
clippy::print_stdout,
clippy::print_stderr,
))]
#![recursion_limit = "1024"]

use anyhow::{anyhow, Result};
Expand Down
2 changes: 1 addition & 1 deletion src/test.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#![allow(clippy::box_default)]
#![allow(clippy::box_default, clippy::print_stdout, clippy::print_stderr)]
//! Test support module; public to permit use from integration tests.

pub mod mock;
Expand Down