SyTen

◆ SYTEN_MPO_EXPECT_ORDER

#define SYTEN_MPO_EXPECT_ORDER (   a,
  b,
  c,
  d,
 
)
Value:
{ \
static_assert(a == 1, f " expects " #a " to be 1"); \
static_assert(b == 2, f " expects " #b " to be 2"); \
static_assert(c == 3, f " expects " #c " to be 3"); \
static_assert(d == 4, f " expects " #c " to be 4"); \
}

Asserts that the supplied macro arguments a, b, c and d are 1 through 4 with the calling funcation named as f.

Example usage: SYTEN_MPO_EXPECT_ORDER(Operator::rIdx, Operator::lIdx, Operator::uIdx, Operator::dIdx, "myfun") to ensure that nobody changes index ordering from below you.