Repository navigation
use cfg!(overflow_checks) in overflow_checks intrinsic instead of cfg!(debug_assertions) - #166295
BioTomateDE wants to merge 1 commit into
Conversation
|
Thanks for the pull request, and welcome! The Rust Project has assigned @JohnTitor (or someone else) to review your changes, you should hear from them (or someone else) within the next two weeks. Please see the contribution instructions and our LLM policy for more information. Why was this reviewer chosen?The reviewer was selected based on:
|
|
As per request: @theemathas |
|
For context, I had an LLM do some investigation. It found the following, which I confirmed to be accurate.
So, I concluded that the fact that the |
This comment has been minimized.
This comment has been minimized.
|
Another small thing I found: the |
|
Do you mind splitting the docs change into another PR? (This PR has @theemathas's investigation of the overflow_checks change, so let's keep that here). You can request my review on the docs one with |
9910e93 to
01d4cf3
Compare
This comment has been minimized.
This comment has been minimized.
|
Given the investigation above, @bors r+ |
|
❌ Cannot approve commit 01d4cf3, because CI currently fails on this PR. Use |
|
Tomorrow I'll check and see if this is passing CI and approve it then if it is. r? @thomcc |
|
📌 Commit 7eca63a has been tentatively approved by It will be put into the queue for this repository once PR CI succeeds. 🌲 The tree is currently closed for pull requests below priority 100. This pull request will be tested once the tree is reopened. Reason for tree closure: |
cfg!(overflow_checks) in overflow_checks intrinsic instead of cfg!(debug_assertions)
|
@bors squash |
This comment has been minimized.
This comment has been minimized.
… `cfg!(debug_assertions)` * use `cfg!(overflow_checks)` in `overflow_checks` intrinsic instead of `cfg!(debug_assertions)` * add missing `cfg_overflow_checks` feature
7eca63a to
f9becad
Compare
|
🔨 2 commits were squashed into f9becad. This pull request was unapproved. |
|
No need to have two commits for such a small change. |
|
📌 Commit f9becad has been tentatively approved by It will be put into the queue for this repository once PR CI succeeds. 🌲 The tree is currently closed for pull requests below priority 100. This pull request will be tested once the tree is reopened. Reason for tree closure: |
The fallback implementation of the
overflow_checks()intrinsic is currently defined as:This seems to be an oversight from copypasting. Its docs state:
I changed its fallback body to
cfg!(overflow_checks).If this is somehow intended behavior, I'd put a comment stating that this
cfg!is intentionallydebug_assertionsinstead ofoverflow_checks.Note: The
overflow_checkscfg is currently unstable, tracked at #111466.Also see https://discord.com/channels/273534239310479360/957720175619215380/1573547547379765341.