Skip to content

Commit b577b26

Browse files
committed
Add stdio configuring to run-make Rustc
1 parent ad7d41c commit b577b26

1 file changed

Lines changed: 24 additions & 0 deletions

File tree

‎src/tools/run-make-support/src/macros.rs‎

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,30 @@ macro_rules! impl_common_helpers {
7070
self
7171
}
7272

73+
/// Configuration for the child process’s standard input (stdin) handle.
74+
///
75+
/// See [`std::process::Command::stdin`].
76+
pubfn stdin<T:Into<Stdio>>(&mutself, cfg:T) -> &mutSelf{
77+
self.cmd.stdin(cfg);
78+
self
79+
}
80+
81+
/// Configuration for the child process’s standard output (stdout) handle.
82+
///
83+
/// See [`std::process::Command::stdout`].
84+
pubfn stdout<T:Into<Stdio>>(&mutself, cfg:T) -> &mutSelf{
85+
self.cmd.stdout(cfg);
86+
self
87+
}
88+
89+
/// Configuration for the child process’s standard error (stderr) handle.
90+
///
91+
/// See [`std::process::Command::stderr`].
92+
pubfn stderr<T:Into<Stdio>>(&mutself, cfg:T) -> &mutSelf{
93+
self.cmd.stderr(cfg);
94+
self
95+
}
96+
7397
/// Inspect what the underlying [`Command`] is up to the
7498
/// current construction.
7599
pubfn inspect<I>(&mutself, inspector:I) -> &mutSelf

0 commit comments

Comments
 (0)