AND51 wrote:Unfortunately, I don't really understand...? Can you explain it in other words again and/or give me an example code?
Ok, these are the rules:
Relational operators are: <, >, =, >=, <=, <>
Boolean operators are: And Or Not Xor
The result of relational and boolean operators can only be given to If, While, Until, And, Or, Not, ElseIf or XOr. This means you can't do ((a=b)+2) because then result of the relational operator is given to the + operator.
Forbidden:
A = B = C ; The result of B = C is not given to If, While, Until, And, Or, Not, ElseIf or XOr.
if (B = C) * D ; The result of B = C is given to the * operator, which is not on this list: If, While, Until, And, Or, Not, ElseIf, XOr.
Allowed:
IF B = C * D ; Multiply, then compare and use the result of the comparision in the IF statement.
IF B = C And B = D ; The result of the ='s are given to AND, the result of the AND is given to the IF.