19-08-2022, 06:21 AM
Quote:A5-2-6 (Required) : The operands of a logical && or \\ shall be parenthesized if the operands contain binary operators.
What about those cases whose oeprands consists of either a sequence of only logical && or ||?
Code:
void f()
{
int a, b, c, d;
if ((a < b) || (b < c) || (c < d)) // compliant or noncompliant
{
}
}