macro_rules! assert_align_ne {
    ($x:ty, $($y:ty),+ $(,)?) => { ... };
}
Expand description

Asserts that the types’ alignments are not equal.

Examples

A u8 does not have the same alignment as a pointer:

assert_align_ne!(u8, *const u8);

The following example fails to compile because a usize has the same alignment as a pointer:

assert_align_ne!(*const u8, usize);