trace! code still present in the generated non-release binary. #386
Labels
No labels
bug
duplicate
easy
enhancement
help wanted
invalid
question
rfc
structured-logging
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
gh-rust-lang/log#386
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
When using
max_level_debugfeature, and compiling a non-release build, my expectation would be thattrace!code is not present in the binary. As mentioned in the documentation:However, the binary still contains some code which is not optimized away by the Rust compiler:
Interesting! Is this still the case today? I’m guessing that’s coming from these checks? https://github.com/rust-lang/log/blob/master/src/macros.rs#L34
I wonder if that’s got anything to do with the
PartialOrdimpl being non-const? It is#[inline]though.