Why does this if statement, with an assignment and equality check, evaluate to false?
The expression is not parsed the way you think. It’s not (test1=false) || (test1 == false) in which case the result would have been true, but test1 = (false || test1 == false) The value of false || test1 == false expression is computed first, and it is false, because test1 is set to true … Read more