Skip to content

Commit

Permalink
Rollup merge of rust-lang#57132 - daxpedda:master, r=steveklabnik
Browse files Browse the repository at this point in the history
Document that `-C opt-level=0` implies `-C debug-assertions`.

I couldn't find it stated anywhere else (https://doc.rust-lang.org/nightly/rustc/codegen-options/index.html#opt-level).
It was a problem before here: rust-lang#39449, it got lost in the migration to the new documentation I assume.

On a sidenote: I think that `-C opt-level=0` having a sideeffect on another flag should be changed. Having compiler flags affecting others doesn't make much sense to me, they are used to fine tune anyway.
In any case, this plays no role in this PR.
  • Loading branch information
Centril committed Jan 18, 2019
2 parents b9cb5db + 284f0d3 commit 04a2cbd
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/doc/rustc/src/codegen-options/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -187,7 +187,7 @@ This flag lets you control debug information:

This flag lets you control the optimization level.

* `0`: no optimizations
* `0`: no optimizations, also turn on `cfg(debug_assertions)`.
* `1`: basic optimizations
* `2`: some optimizations
* `3`: all optimizations
Expand Down

0 comments on commit 04a2cbd

Please sign in to comment.