Skip to content

Commit

Permalink
fix(*): miri build failure
Browse files Browse the repository at this point in the history
  • Loading branch information
wvwwvwwv committed Sep 30, 2024
1 parent 1c22902 commit ac0dc94
Showing 1 changed file with 0 additions and 34 deletions.
34 changes: 0 additions & 34 deletions src/tests/correctness.rs
Original file line number Diff line number Diff line change
Expand Up @@ -14,21 +14,13 @@ mod hashmap_test {
use std::sync::Arc;
use tokio::sync::Barrier as AsyncBarrier;

#[cfg(not(miri))]
static_assertions::assert_impl_all!(HashMap<String, String>: Send, Sync, UnwindSafe);
#[cfg(not(miri))]
static_assertions::assert_impl_all!(Reserve<String, String>: Send, Sync, UnwindSafe);
#[cfg(not(miri))]
static_assertions::assert_not_impl_all!(HashMap<String, *const String>: Send, Sync, UnwindSafe);
#[cfg(not(miri))]
static_assertions::assert_not_impl_all!(Reserve<String, *const String>: Send, Sync, UnwindSafe);
#[cfg(not(miri))]
static_assertions::assert_impl_all!(hash_map::OccupiedEntry<String, String>: Send, Sync);
#[cfg(not(miri))]
static_assertions::assert_not_impl_all!(hash_map::OccupiedEntry<String, *const String>: Send, Sync, UnwindSafe);
#[cfg(not(miri))]
static_assertions::assert_impl_all!(hash_map::VacantEntry<String, String>: Send, Sync);
#[cfg(not(miri))]
static_assertions::assert_not_impl_all!(hash_map::VacantEntry<String, *const String>: Send, Sync, UnwindSafe);

struct R(&'static AtomicUsize);
Expand Down Expand Up @@ -824,13 +816,9 @@ mod hashindex_test {
use std::thread;
use tokio::sync::Barrier as AsyncBarrier;

#[cfg(not(miri))]
static_assertions::assert_impl_all!(HashIndex<String, String>: Send, Sync, UnwindSafe);
#[cfg(not(miri))]
static_assertions::assert_impl_all!(Iter<'static, 'static, String, String>: UnwindSafe);
#[cfg(not(miri))]
static_assertions::assert_not_impl_all!(HashIndex<String, *const String>: Send, Sync, UnwindSafe);
#[cfg(not(miri))]
static_assertions::assert_not_impl_all!(Iter<'static, 'static, String, *const String>: Send, Sync, UnwindSafe);

struct R(&'static AtomicUsize);
Expand Down Expand Up @@ -1438,9 +1426,7 @@ mod hashset_test {
use crate::HashSet;
use std::panic::UnwindSafe;

#[cfg(not(miri))]
static_assertions::assert_impl_all!(HashSet<String>: Send, Sync, UnwindSafe);
#[cfg(not(miri))]
static_assertions::assert_not_impl_all!(HashSet<*const String>: Send, Sync, UnwindSafe);

#[test]
Expand Down Expand Up @@ -1478,17 +1464,11 @@ mod hashcache_test {
use std::sync::Arc;
use tokio::sync::Barrier as AsyncBarrier;

#[cfg(not(miri))]
static_assertions::assert_impl_all!(HashCache<String, String>: Send, Sync, UnwindSafe);
#[cfg(not(miri))]
static_assertions::assert_not_impl_all!(HashCache<String, *const String>: Send, Sync, UnwindSafe);
#[cfg(not(miri))]
static_assertions::assert_impl_all!(hash_cache::OccupiedEntry<String, String>: Send, Sync);
#[cfg(not(miri))]
static_assertions::assert_not_impl_all!(hash_cache::OccupiedEntry<String, *const String>: Send, Sync, UnwindSafe);
#[cfg(not(miri))]
static_assertions::assert_impl_all!(hash_cache::VacantEntry<String, String>: Send, Sync);
#[cfg(not(miri))]
static_assertions::assert_not_impl_all!(hash_cache::VacantEntry<String, *const String>: Send, Sync, UnwindSafe);

struct R(&'static AtomicUsize);
Expand Down Expand Up @@ -1835,17 +1815,11 @@ mod treeindex_test {
use tokio::sync::Barrier as AsyncBarrier;
use tokio::task;

#[cfg(not(miri))]
static_assertions::assert_impl_all!(TreeIndex<String, String>: Send, Sync, UnwindSafe);
#[cfg(not(miri))]
static_assertions::assert_impl_all!(Iter<'static, 'static, String, String>: UnwindSafe);
#[cfg(not(miri))]
static_assertions::assert_impl_all!(Range<'static, 'static, String, String, String, RangeInclusive<String>>: UnwindSafe);
#[cfg(not(miri))]
static_assertions::assert_not_impl_all!(TreeIndex<String, *const String>: Send, Sync, UnwindSafe);
#[cfg(not(miri))]
static_assertions::assert_not_impl_all!(Iter<'static, 'static, String, *const String>: Send, Sync, UnwindSafe);
#[cfg(not(miri))]
static_assertions::assert_not_impl_all!(Range<'static, 'static, String, *const String, String, RangeInclusive<String>>: Send, Sync, UnwindSafe);

struct R(&'static AtomicUsize);
Expand Down Expand Up @@ -2626,13 +2600,9 @@ mod bag_test {
use tokio::sync::Barrier as AsyncBarrier;
use tokio::task;

#[cfg(not(miri))]
static_assertions::assert_impl_all!(Bag<String>: Send, Sync, UnwindSafe);
#[cfg(not(miri))]
static_assertions::assert_impl_all!(IterMut<'static, String>: Send, Sync, UnwindSafe);
#[cfg(not(miri))]
static_assertions::assert_not_impl_all!(Bag<*const String>: Send, Sync, UnwindSafe);
#[cfg(not(miri))]
static_assertions::assert_not_impl_all!(IterMut<'static, *const String>: Send, Sync, UnwindSafe);

struct R(&'static AtomicUsize);
Expand Down Expand Up @@ -2813,9 +2783,7 @@ mod queue_test {
use std::sync::{Arc, Barrier};
use std::thread;

#[cfg(not(miri))]
static_assertions::assert_impl_all!(Queue<String>: Send, Sync, UnwindSafe);
#[cfg(not(miri))]
static_assertions::assert_not_impl_all!(Queue<*const String>: Send, Sync, UnwindSafe);

struct R(&'static AtomicUsize, usize, usize);
Expand Down Expand Up @@ -3008,9 +2976,7 @@ mod stack_test {
use std::{panic::UnwindSafe, sync::Arc};
use tokio::sync::Barrier as AsyncBarrier;

#[cfg(not(miri))]
static_assertions::assert_impl_all!(Stack<String>: Send, Sync, UnwindSafe);
#[cfg(not(miri))]
static_assertions::assert_not_impl_all!(Stack<*const String>: Send, Sync, UnwindSafe);

#[derive(Debug)]
Expand Down

0 comments on commit ac0dc94

Please sign in to comment.