RAD Studio
ContentsIndex
PreviousUpNext
W8084: Suggest parentheses to clarify precedence (C++)

This warning indicates that several operators used in one expression might cause confusion about the applicable operator precedence rules. The warning helps create code that is more easy to understand and potentially less ambiguous. 

For example, compile the following code using the –w command line option:

int j, k, l;
int main()
{
  return j < k & l;  // This causes an error
}
// 
Copyright(C) 2009 Embarcadero Technologies, Inc. All Rights Reserved.
What do you think about this topic? Send feedback!