Quuxplusone added a comment. LGTM % comments, FWIW.
================ Comment at: clang/test/Sema/warn-bitwise-and-bool.c:26 + b = foo() & a; + b = (p != 0) & (*p == 42); + b = foo() & (*q == 42); // expected-warning {{use of bitwise '&' with boolean operands}} ---------------- Perhaps add a `TODO FIXME` comment here? I still think this should be fixed, but I'm willing to believe that it's unduly difficult and defer it to later. :) ================ Comment at: clang/test/Sema/warn-bitwise-and-bool.c:27 + b = (p != 0) & (*p == 42); + b = foo() & (*q == 42); // expected-warning {{use of bitwise '&' with boolean operands}} + b = a & foo(); ---------------- For each warning case (or at least for one or two of them), could we also test (my suggested) suppression mechanism? I think it "obviously" just works, but it'd be good to test explicitly that it works. ``` b = foo() & (int)(*q == 42); // OK, no warning expected ``` CHANGES SINCE LAST ACTION https://reviews.llvm.org/D108003/new/ https://reviews.llvm.org/D108003 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits