-
Notifications
You must be signed in to change notification settings - Fork 2.5k
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Allow configuring -C debug-assertions setting #1398
Labels
Comments
alexcrichton
added a commit
to alexcrichton/cargo
that referenced
this issue
Mar 24, 2015
This commit removes the ndebug support from Cargo and also adds a new configuration option for profiles, `debug-assertions`, which controls whether debug assertions in the compiler are turned on or not. Closes rust-lang#1398
bors
added a commit
that referenced
this issue
Mar 24, 2015
This commit removes the ndebug support from Cargo and also adds a new configuration option for profiles, `debug-assertions`, which controls whether debug assertions in the compiler are turned on or not. Closes #1398
alexcrichton
added a commit
to alexcrichton/cargo
that referenced
this issue
Mar 24, 2015
This commit removes the ndebug support from Cargo and also adds a new configuration option for profiles, `debug-assertions`, which controls whether debug assertions in the compiler are turned on or not. Closes rust-lang#1398
bors
added a commit
that referenced
this issue
Mar 24, 2015
This commit removes the ndebug support from Cargo and also adds a new configuration option for profiles, `debug-assertions`, which controls whether debug assertions in the compiler are turned on or not. Closes #1398
# for free
to join this conversation on GitHub.
Already have an account?
# to comment
cargo currently passes
-g
when debugging is on and--cfg ndebug
when debugging is off:The rust compiler recently stopped using
--cfg ndebug
to controldebug_assert!
and instead uses#[cfg(debug_assertions)]
, enabled when the optimization-level is 0, and overridable using-C debug-assertions
(RFC 563)We may want to add a
debug_assertions
profile setting like the existingopt-level
anddebug
settings. Even if we don't, though, we should at least stop passing--cfg ndebug
.The text was updated successfully, but these errors were encountered: