Minor type fix (they're both enums/ints, so the compiler previously
silently cast them).