Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix Stdio::piped example code and lint #64294

Merged
merged 1 commit into from
Sep 23, 2019

Conversation

wchargin
Copy link
Contributor

@wchargin wchargin commented Sep 8, 2019

Summary:
Invoking rev does not add a trailing newline when none is present in
the input (at least on my Debian). Nearby examples use echo rather
than rev, which probably explains the source of the discrepancy.

Also, a mut qualifier is unused.

Test Plan:
Copy the code block into https://play.rust-lang.org with a fn main
wrapper, and run it. Note that it compiles and runs cleanly; prior to
this commit, it would emit an unused_mut warning and then panic.

wchargin-branch: stdio-piped-docs

Summary:
Invoking `rev` does not add a trailing newline when none is present in
the input (at least on my Debian). Nearby examples use `echo` rather
than `rev`, which probably explains the source of the discrepancy.

Also, a `mut` qualifier is unused.

Test Plan:
Copy the code block into <https://play.rust-lang.org> with a `fn main`
wrapper, and run it. Note that it compiles and runs cleanly; prior to
this commit, it would emit an `unused_mut` warning and then panic.

wchargin-branch: stdio-piped-docs
@rust-highfive
Copy link
Collaborator

Thanks for the pull request, and welcome! The Rust team is excited to review your changes, and you should hear from @withoutboats (or someone else) soon.

If any changes to this PR are deemed necessary, please add them as extra commits. This ensures that the reviewer can see what has changed since they last reviewed the code. Due to the way GitHub handles out-of-date commits, this should also make it reasonably obvious what issues have or haven't been addressed. Large or tricky changes may require several passes of review and changes.

Please see the contribution instructions for more information.

@rust-highfive rust-highfive added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Sep 8, 2019
@JohnCSimon
Copy link
Member

Ping from triage
@withoutboats Can you please review this PR? Thank you.

Thanks.

@JohnCSimon
Copy link
Member

Pinging from triage
@withoutboats Can you please review this PR? This has sat idle for 12 days. Thank you.

@Dylan-DPC-zz
Copy link

@bors: r+

@bors
Copy link
Contributor

bors commented Sep 21, 2019

📌 Commit 9bf5773 has been approved by Dylan-DPC

@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Sep 21, 2019
@Centril
Copy link
Contributor

Centril commented Sep 21, 2019

r? @Dylan-DPC

Centril added a commit to Centril/rust that referenced this pull request Sep 22, 2019
… r=Dylan-DPC

Fix `Stdio::piped` example code and lint

Summary:
Invoking `rev` does not add a trailing newline when none is present in
the input (at least on my Debian). Nearby examples use `echo` rather
than `rev`, which probably explains the source of the discrepancy.

Also, a `mut` qualifier is unused.

Test Plan:
Copy the code block into <https://play.rust-lang.org> with a `fn main`
wrapper, and run it. Note that it compiles and runs cleanly; prior to
this commit, it would emit an `unused_mut` warning and then panic.

wchargin-branch: stdio-piped-docs
Centril added a commit to Centril/rust that referenced this pull request Sep 22, 2019
… r=Dylan-DPC

Fix `Stdio::piped` example code and lint

Summary:
Invoking `rev` does not add a trailing newline when none is present in
the input (at least on my Debian). Nearby examples use `echo` rather
than `rev`, which probably explains the source of the discrepancy.

Also, a `mut` qualifier is unused.

Test Plan:
Copy the code block into <https://play.rust-lang.org> with a `fn main`
wrapper, and run it. Note that it compiles and runs cleanly; prior to
this commit, it would emit an `unused_mut` warning and then panic.

wchargin-branch: stdio-piped-docs
bors added a commit that referenced this pull request Sep 23, 2019
Rollup of 7 pull requests

Successful merges:

 - #64294 (Fix `Stdio::piped` example code and lint)
 - #64670 (Cleanup syntax::ext::build)
 - #64674 (Propagate `types.err` in locals further to avoid spurious knock-down errors)
 - #64676 (Parse assoc type bounds in generic params and provide custom diagnostic)
 - #64677 (remove outdated comment)
 - #64679 (Infer consts more consistently)
 - #64688 (Clarify the "since" tidy check)

Failed merges:

r? @ghost
@bors bors merged commit 9bf5773 into rust-lang:master Sep 23, 2019
@wchargin
Copy link
Contributor Author

Thanks for the review! :-)

@wchargin wchargin deleted the wchargin-stdio-piped-docs branch September 23, 2019 15:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants