You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The name mimics other {kind}_assert!s like debug_assert!, as well as core's ub-checks one (assert_unsafe_precondition!).
Please double check if there are already asserts out there (or perhaps even new ones) that could make use of it, and transform (or add) them in a second patch etc.
This requires submitting a proper patch to the LKML and the Rust for Linux mailing list. Please recall to test your changes (including generating the documentation if changed, running the Rust doctests if changed, etc.), to use a proper title for the commit, to sign your commit under the Developer's Certificate of Origin and to add a Suggested-by: tag, and a Link: tag to this issue. Please see https://docs.kernel.org/process/submitting-patches.html and https://rust-for-linux.com/contributing for details.
So if you expect to take long to send it, it may be a good idea to still post a note here (but of course there is no need to ask for permission to start, if that makes sense).
Yeah, I meant it as "it could be either", or perhaps "in-between", depending on the person and/or the discussion in the list, so that people would find it if searching for either of the tags. I did it in others too, I think. But if it is confusing, we can remove it.
Activity
hz2 commentedon Apr 29, 2025
hi id like to take this on
ojeda commentedon Apr 29, 2025
Sure, thanks, please go ahead!
(For other readers/future issues: no need to mention it -- you all can just send the patch! :)
hz2 commentedon Apr 29, 2025
thank you!
for future reference, is there a way to check if a issue is already being worked on?
ojeda commentedon Apr 29, 2025
You're welcome!
Unless someone posts here, not really (one may want to search Lore for the issue link, though, e.g. https://lore.kernel.org/rust-for-linux/?q=https%3A%2F%2Fgithub.com%2FRust-for-Linux%2Flinux%2Fissues%2F1126.
So if you expect to take long to send it, it may be a good idea to still post a note here (but of course there is no need to ask for permission to start, if that makes sense).
BennoLossin commentedon Apr 30, 2025
@ojeda fyi this issue is both labeled easy and medium, is that intentional? (#1159 also has both labels)
ojeda commentedon Apr 30, 2025
Yeah, I meant it as "it could be either", or perhaps "in-between", depending on the person and/or the discussion in the list, so that people would find it if searching for either of the tags. I did it in others too, I think. But if it is confusing, we can remove it.
rust: kernel: introduce `unsafe_precondition_assert!` macro
rust: kernel: introduce `unsafe_precondition_assert!` macro
rust: kernel: introduce `unsafe_precondition_assert!` macro
rust: kernel: introduce `unsafe_precondition_assert!` macro
rust: kernel: introduce `unsafe_precondition_assert!` macro
rust: kernel: introduce `unsafe_precondition_assert!` macro
rust: kernel: introduce `unsafe_precondition_assert!` macro
rust: kernel: introduce `unsafe_precondition_assert!` macro
rust: safety: introduce `unsafe_precondition_assert!` macro
rust: safety: introduce `unsafe_precondition_assert!` macro
rust: safety: introduce `unsafe_precondition_assert!` macro
ojeda commentedon Feb 2, 2026
Lore: https://lore.kernel.org/rust-for-linux/20251007215034.213779-1-ritvikfoss@gmail.com/
Applied to
rust-next-- thanks!