[codeview] Fix sense of the assertion about hashtable insertion
authorReid Kleckner <rnk@google.com>
Thu, 15 Mar 2018 21:18:42 +0000 (21:18 +0000)
committerReid Kleckner <rnk@google.com>
Thu, 15 Mar 2018 21:18:42 +0000 (21:18 +0000)
llvm-svn: 327669

llvm/lib/CodeGen/AsmPrinter/CodeViewDebug.cpp

index 1ffc589..89a7974 100644 (file)
@@ -1163,7 +1163,7 @@ void CodeViewDebug::collectVariableInfo(const DISubprogram *SP) {
 void CodeViewDebug::beginFunctionImpl(const MachineFunction *MF) {
   const Function &GV = MF->getFunction();
   auto Insertion = FnDebugInfo.insert({&GV, llvm::make_unique<FunctionInfo>()});
-  assert(!Insertion.second && "emitting function twice");
+  assert(Insertion.second && "function already has info");
   CurFn = Insertion.first->second.get();
   CurFn->FuncId = NextFuncId++;
   CurFn->Begin = Asm->getFunctionBegin();