Macro std::const_assert_ne
Aborts the compilation if lhs
and rhs
are equal during compilation.
lhs
and rhs
must be constant expressions.
Examples
use std::const_assert_ne;
const_assert_ne!(1 + 1, 3);
Run this example
use std::const_assert_ne;
const_assert_ne!(1 + 1, 2); // fails to compile
Run this example