https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81271

            Bug ID: 81271
           Summary: gcc/cp/lex.c:116: wrong condition ?
           Product: gcc
           Version: 7.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c++
          Assignee: unassigned at gcc dot gnu.org
          Reporter: dcb314 at hotmail dot com
  Target Milestone: ---

trunk/gcc/cp/lex.c:116]: (style) Boolean result is used in bitwise operation.
Clarify expression with parentheses.

Source code is

  gcc_checking_assert (!IDENTIFIER_KIND_BIT_2 (id)
               & !IDENTIFIER_KIND_BIT_1 (id)
               & !IDENTIFIER_KIND_BIT_0 (id));

Maybe better code

  gcc_checking_assert (!IDENTIFIER_KIND_BIT_2 (id)
               && !IDENTIFIER_KIND_BIT_1 (id)
               && !IDENTIFIER_KIND_BIT_0 (id));

Reply via email to