From f5c0689e92ec46a7f3ec06f4dd8725c9d858b0dd Mon Sep 17 00:00:00 2001 From: David Majnemer Date: Mon, 31 Oct 2016 17:11:23 +0000 Subject: SymbolRef::Type is not a bitfield and must be compared directly Found by PVS-Studio. llvm-svn: 285597 --- llvm/tools/dsymutil/MachODebugMapParser.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'llvm/tools') diff --git a/llvm/tools/dsymutil/MachODebugMapParser.cpp b/llvm/tools/dsymutil/MachODebugMapParser.cpp index e5a0535949d..051c1e941ef 100644 --- a/llvm/tools/dsymutil/MachODebugMapParser.cpp +++ b/llvm/tools/dsymutil/MachODebugMapParser.cpp @@ -445,7 +445,7 @@ void MachODebugMapParser::loadMainBinarySymbols( } SymbolRef::Type Type = *TypeOrErr; // Skip undefined and STAB entries. - if ((Type & SymbolRef::ST_Debug) || (Type & SymbolRef::ST_Unknown)) + if ((Type == SymbolRef::ST_Debug) || (Type == SymbolRef::ST_Unknown)) continue; // The only symbols of interest are the global variables. These // are the only ones that need to be queried because the address -- cgit v1.2.3