Export (0) Print
Expand All
Expand Minimize
0 out of 4 rated this helpful - Rate this topic

Compiler Warning (level 3) C4554

Error Message

'operator' : check operator precedence for possible error; use parentheses to clarify precedence

The following sample generates C4554:

// C4554.cpp
// compile with: /W3 /WX
int main() {
   int a = 0, b = 0, c = 0;
   a = a << b + c;   // C4554
   // probably intended (a << b) + c,
   // but will get a << (b + c)
}
Did you find this helpful?
(1500 characters remaining)
Thank you for your feedback

Community Additions

ADD
Show:
© 2014 Microsoft. All rights reserved.