1
Fork 0

Rollup merge of #115535 - tshepang:patch-2, r=dtolnay

format doc-comment code examples in std::process
This commit is contained in:
Matthias Krüger 2023-09-28 09:14:05 +02:00 committed by GitHub
commit 0e338d7e23
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -158,8 +158,7 @@ use crate::sys_common::{AsInner, AsInnerMut, FromInner, IntoInner};
/// .spawn() /// .spawn()
/// .expect("failed to execute child"); /// .expect("failed to execute child");
/// ///
/// let ecode = child.wait() /// let ecode = child.wait().expect("failed to wait on child");
/// .expect("failed to wait on child");
/// ///
/// assert!(ecode.success()); /// assert!(ecode.success());
/// ``` /// ```
@ -502,8 +501,7 @@ impl fmt::Debug for ChildStderr {
/// use std::process::Command; /// use std::process::Command;
/// ///
/// let mut echo_hello = Command::new("sh"); /// let mut echo_hello = Command::new("sh");
/// echo_hello.arg("-c") /// echo_hello.arg("-c").arg("echo hello");
/// .arg("echo hello");
/// let hello_1 = echo_hello.output().expect("failed to execute process"); /// let hello_1 = echo_hello.output().expect("failed to execute process");
/// let hello_2 = echo_hello.output().expect("failed to execute process"); /// let hello_2 = echo_hello.output().expect("failed to execute process");
/// ``` /// ```