]> granicus.if.org Git - clang/commitdiff
Use a more conventional logical op instead of bitwise and
authorAlp Toker <alp@nuanti.com>
Mon, 24 Feb 2014 04:35:58 +0000 (04:35 +0000)
committerAlp Toker <alp@nuanti.com>
Mon, 24 Feb 2014 04:35:58 +0000 (04:35 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@202006 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Lex/Preprocessor.cpp

index 1e54ab372516e1891932d361ca586abde9936d11..e7d844087c0216bac440161e8e58f241a4b553ee 100644 (file)
@@ -627,7 +627,7 @@ bool Preprocessor::HandleIdentifier(Token &Identifier) {
   // name of a macro.
   // FIXME: This warning is disabled in cases where it shouldn't be, like
   //   "#define constexpr constexpr", "int constexpr;"
-  if (II.isCXX11CompatKeyword() & !DisableMacroExpansion) {
+  if (II.isCXX11CompatKeyword() && !DisableMacroExpansion) {
     Diag(Identifier, diag::warn_cxx11_keyword) << II.getName();
     // Don't diagnose this keyword again in this translation unit.
     II.setIsCXX11CompatKeyword(false);