Check x86_64 size assertions on aarch64, too
This makes it easier for contributors on aarch64 workstations (e.g. Macs) to notice when these assertions have been violated.
This commit is contained in:
@@ -339,7 +339,7 @@ macro_rules! define_callbacks {
|
||||
pub type Storage<'tcx> = <$($K)* as keys::Key>::Cache<Erase<$V>>;
|
||||
|
||||
// Ensure that keys grow no larger than 64 bytes
|
||||
#[cfg(all(target_arch = "x86_64", target_pointer_width = "64"))]
|
||||
#[cfg(all(any(target_arch = "x86_64", target_arch="aarch64"), target_pointer_width = "64"))]
|
||||
const _: () = {
|
||||
if mem::size_of::<Key<'static>>() > 64 {
|
||||
panic!("{}", concat!(
|
||||
@@ -353,7 +353,7 @@ macro_rules! define_callbacks {
|
||||
};
|
||||
|
||||
// Ensure that values grow no larger than 64 bytes
|
||||
#[cfg(all(target_arch = "x86_64", target_pointer_width = "64"))]
|
||||
#[cfg(all(any(target_arch = "x86_64", target_arch="aarch64"), target_pointer_width = "64"))]
|
||||
const _: () = {
|
||||
if mem::size_of::<Value<'static>>() > 64 {
|
||||
panic!("{}", concat!(
|
||||
|
||||
Reference in New Issue
Block a user