ctSelectBool static method
Branchless select: returns b if choice else a.
Implementation
static bool ctSelectBool(bool a, bool b, bool choice) {
final ai = a ? 1 : 0;
final bi = b ? 1 : 0;
final mask = choice ? -1 : 0; // 0 or -1
final si = ai ^ (mask & (ai ^ bi));
return si != 0;
}