Fix boolean logic associativity bug.