Skip to content

Commit

Permalink
fix warning when building libcore for Miri
Browse files Browse the repository at this point in the history
  • Loading branch information
RalfJung committed Mar 9, 2024
1 parent 1b427b3 commit 6aff1ca
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions library/core/src/intrinsics.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3120,6 +3120,7 @@ pub(crate) const fn miri_promise_symbolic_alignment(ptr: *const (), align: usize

const fn compiletime(_ptr: *const (), _align: usize) {}

#[cfg_attr(not(bootstrap), allow(unused_unsafe))] // on bootstrap bump, remove unsafe block
// SAFETY: the extra behavior at runtime is for UB checks only.
unsafe {
const_eval_select((ptr, align), compiletime, runtime);
Expand Down

0 comments on commit 6aff1ca

Please sign in to comment.