mirror of
https://github.com/rust-lang/rust.git
synced 2024-11-02 07:22:42 +00:00
fix a warning when building core tests with cfg(miri)
This commit is contained in:
parent
32cbc7630b
commit
d233570fab
@ -2457,9 +2457,11 @@ take_tests! {
|
||||
(take_last_mut_empty, (), None, &mut []),
|
||||
}
|
||||
|
||||
#[cfg(not(miri))] // unused in Miri
|
||||
const EMPTY_MAX: &'static [()] = &[(); usize::MAX];
|
||||
|
||||
// can't be a constant due to const mutability rules
|
||||
#[cfg(not(miri))] // unused in Miri
|
||||
macro_rules! empty_max_mut {
|
||||
() => {
|
||||
&mut [(); usize::MAX] as _
|
||||
|
Loading…
Reference in New Issue
Block a user