-
Notifications
You must be signed in to change notification settings - Fork 12.8k
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 doc for rustc "-g" flag #58544
Fix doc for rustc "-g" flag #58544
Conversation
Some changes occurred in HTML/CSS. |
Thanks for the pull request, and welcome! The Rust team is excited to review your changes, and you should hear from @TimNN (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. |
a59ae5a
to
03d625b
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
One nit, otherwise LGTM.
@@ -42,11 +42,11 @@ This flag prints out various information about the compiler. | |||
|
|||
## `-g`: include debug information | |||
|
|||
A synonym for `-C debug-level=2`. | |||
A synonym for `-C debuglevel=2`, for more see [here](codegen-options/index.html#debuginfo). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looking at the output of rustc +stable -C help
, it looks like this should actually be debuginfo
.
03d625b
to
192a0c4
Compare
The rustc "-g" CLI flag was miss documented to be a synonym of "-C debug-level=2" and not the correct "-C debuginfo=2".
The rustc "-g" and "-o" fags are synonyms of the "-c" codegen flags. This adds a link to the codegen docs for each synonym.
192a0c4
to
88e462b
Compare
I don't get why I was cced in here since there are no changes in HTML/CSS/JS but whatever... Looks good to me, thanks! @bors: r=TimNN |
📌 Commit 88e462b has been approved by |
Sorry for the first version not having the correct arg. A bit of a fail trying to fix a typo with another one. I have just ran the full set of tests and check the doc links work locally. The only question I have is if |
…TimNN Fix doc for rustc "-g" flag The rustc `-g` CLI flag was miss documented to be a synonym of `-C debug-level=2` and not `-C debuglevel=2`. Also add links to the codegen docs for each synonym. I am unsure of this will conflict with work on rust-lang#52938
My quick check of the code found that LLVM uses rustcrust/src/librustc/session/config.rs Lines 1684 to 1685 in f47ec2a
llvm |
…TimNN Fix doc for rustc "-g" flag The rustc `-g` CLI flag was miss documented to be a synonym of `-C debug-level=2` and not `-C debuglevel=2`. Also add links to the codegen docs for each synonym. I am unsure of this will conflict with work on rust-lang#52938
@bors rollup |
…TimNN Fix doc for rustc "-g" flag The rustc `-g` CLI flag was miss documented to be a synonym of `-C debug-level=2` and not `-C debuglevel=2`. Also add links to the codegen docs for each synonym. I am unsure of this will conflict with work on rust-lang#52938
…TimNN Fix doc for rustc "-g" flag The rustc `-g` CLI flag was miss documented to be a synonym of `-C debug-level=2` and not `-C debuglevel=2`. Also add links to the codegen docs for each synonym. I am unsure of this will conflict with work on rust-lang#52938
Rollup of 24 pull requests Successful merges: - #56470 (Modify doctest's auto-`fn main()` to allow `Result`s) - #58044 (Make overflowing and wrapping negation const) - #58303 (Improve stability tags display) - #58336 (Fix search results interactions) - #58384 (Fix tables display) - #58392 (Use less explicit shifting in std::net::ip) - #58409 (rustdoc: respect alternate flag when formatting impl trait) - #58456 (Remove no longer accurate diagnostic code about NLL) - #58528 (Don't use an allocation for ItemId in StmtKind) - #58530 (Monomorphize less code in fs::{read|write}) - #58534 (Mention capping forbid lints) - #58536 (Remove UB in pointer tests) - #58538 (Add missing fmt structs examples) - #58539 (Add alias methods to PathBuf for underlying OsString (#58234)) - #58544 (Fix doc for rustc "-g" flag) - #58545 (Add regression test for a specialization-related ICE (#39448)) - #58546 (librustc_codegen_llvm => 2018) - #58551 (Explain a panic in test case net::tcp::tests::double_bind) - #58553 (Use more impl header lifetime elision) - #58562 (Fix style nits) - #58565 (Fix typo in std::future::Future docs) - #58568 (Fix a transposition in driver.rs.) - #58569 (Reduce Some Code Repetitions like `(n << amt) >> amt`) - #58576 (Stabilize iter::successors and iter::from_fn)
Rollup of 24 pull requests Successful merges: - #56470 (Modify doctest's auto-`fn main()` to allow `Result`s) - #58044 (Make overflowing and wrapping negation const) - #58303 (Improve stability tags display) - #58336 (Fix search results interactions) - #58384 (Fix tables display) - #58392 (Use less explicit shifting in std::net::ip) - #58409 (rustdoc: respect alternate flag when formatting impl trait) - #58456 (Remove no longer accurate diagnostic code about NLL) - #58528 (Don't use an allocation for ItemId in StmtKind) - #58530 (Monomorphize less code in fs::{read|write}) - #58534 (Mention capping forbid lints) - #58536 (Remove UB in pointer tests) - #58538 (Add missing fmt structs examples) - #58539 (Add alias methods to PathBuf for underlying OsString (#58234)) - #58544 (Fix doc for rustc "-g" flag) - #58545 (Add regression test for a specialization-related ICE (#39448)) - #58546 (librustc_codegen_llvm => 2018) - #58551 (Explain a panic in test case net::tcp::tests::double_bind) - #58553 (Use more impl header lifetime elision) - #58562 (Fix style nits) - #58565 (Fix typo in std::future::Future docs) - #58568 (Fix a transposition in driver.rs.) - #58569 (Reduce Some Code Repetitions like `(n << amt) >> amt`) - #58576 (Stabilize iter::successors and iter::from_fn)
The rustc
-g
CLI flag was miss documented to be a synonym of-C debug-level=2
and not-C debuglevel=2
. Also add links to the codegen docs for each synonym.I am unsure of this will conflict with work on #52938