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

--print link-args does not print a newline #127507

Closed
tgross35 opened this issue Jul 9, 2024 · 2 comments · Fixed by #127512
Closed

--print link-args does not print a newline #127507

tgross35 opened this issue Jul 9, 2024 · 2 comments · Fixed by #127512
Assignees
Labels
A-cli Area: Command line interface to the compiler. C-bug Category: This is a bug. E-easy Call for participation: Easy difficulty. Experience needed to fix: Not much. Good first issue. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.

Comments

@tgross35
Copy link
Contributor

tgross35 commented Jul 9, 2024

Running with --print link-args doesn't include a trailing \n so the next shell prompt gets smooshed on:

root@886c7cdb990c:/home# rustc a.rs --print link-args
LC_ALL="C" PATH="/root/.rustup/ /* SNIP */ "-pie" "-Wl,-z,relro,-z,now" "-nodefaultlibs"root@886c7cdb990c:/home#

I can't imagine this is intentional since all other --print options seem to include the newline.

rustc 1.81.0-nightly (35b658fb1 2024-07-08)
binary: rustc
commit-hash: 35b658fb1071d752d092751d9f17a9fa7b154ec4
commit-date: 2024-07-08
host: aarch64-unknown-linux-gnu
release: 1.81.0-nightly
LLVM version: 18.1.7
@tgross35 tgross35 added the C-bug Category: This is a bug. label Jul 9, 2024
@rustbot rustbot added the needs-triage This issue may need triage. Remove it if it has been sufficiently triaged. label Jul 9, 2024
@tgross35
Copy link
Contributor Author

tgross35 commented Jul 9, 2024

@rustbot label +E-easy +A-cli +T-compiler -needs-triage

@rustbot rustbot added A-cli Area: Command line interface to the compiler. E-easy Call for participation: Easy difficulty. Experience needed to fix: Not much. Good first issue. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. and removed needs-triage This issue may need triage. Remove it if it has been sufficiently triaged. labels Jul 9, 2024
@eggyal
Copy link
Contributor

eggyal commented Jul 9, 2024

@rustbot claim

@bors bors closed this as completed in 8840d30 Jul 17, 2024
rust-timer added a commit to rust-lang-ci/rust that referenced this issue Jul 17, 2024
Rollup merge of rust-lang#127512 - eggyal:newline-terminate-print-linkargs, r=compiler-errors

Terminate `--print link-args` output with newline

Fixes rust-lang#127507
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-cli Area: Command line interface to the compiler. C-bug Category: This is a bug. E-easy Call for participation: Easy difficulty. Experience needed to fix: Not much. Good first issue. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants