Skip to content

Commit 70b51da

Browse files
committed
miri
1 parent 62eb23d commit 70b51da

File tree

1 file changed

+9
-1
lines changed

1 file changed

+9
-1
lines changed

src/lib.rs

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -427,7 +427,15 @@ macro_rules! load_v {
427427
std::ptr::copy_nonoverlapping($sptr, $placeholder[..].as_mut_ptr(), $nb);
428428
load($placeholder[..].as_ptr())
429429
} else {
430-
load($sptr)
430+
#[cfg(miri)]
431+
{
432+
std::ptr::copy_nonoverlapping($sptr, $placeholder[..].as_mut_ptr(), $nb);
433+
load($placeholder[..].as_ptr())
434+
}
435+
#[cfg(not(miri))]
436+
{
437+
load($sptr)
438+
}
431439
}
432440
}
433441
}};

0 commit comments

Comments
 (0)