Member predicate BadTypeof::EqOrSwitch::getAnOperand

Gets an operand of this comparison.

For equality tests, the result is one of the operands; for switch cases, the result is either the case expression or the discriminant of the switch statement.

Thus, the operands of x !== 0 are x and 0, while the operands of case 1: in switch (y) { case 1: ... } are y and 1.

Expr getAnOperand()