r304397 - Fixed warnings

Piotr Padlewski via cfe-commits cfe-commits at lists.llvm.org
Thu Jun 1 02:24:37 PDT 2017


Author: prazek
Date: Thu Jun  1 04:24:36 2017
New Revision: 304397

URL: http://llvm.org/viewvc/llvm-project?rev=304397&view=rev
Log:
Fixed warnings

Modified:
    cfe/trunk/include/clang/AST/VTableBuilder.h
    cfe/trunk/lib/CodeGen/CodeGenModule.cpp

Modified: cfe/trunk/include/clang/AST/VTableBuilder.h
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/include/clang/AST/VTableBuilder.h?rev=304397&r1=304396&r2=304397&view=diff
==============================================================================
--- cfe/trunk/include/clang/AST/VTableBuilder.h (original)
+++ cfe/trunk/include/clang/AST/VTableBuilder.h Thu Jun  1 04:24:36 2017
@@ -173,6 +173,7 @@ public:
     case CK_UnusedFunctionPointer:
       llvm_unreachable("Only function pointers kinds");
     }
+    llvm_unreachable("Should already return");
   }
 
 private:

Modified: cfe/trunk/lib/CodeGen/CodeGenModule.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/CodeGen/CodeGenModule.cpp?rev=304397&r1=304396&r2=304397&view=diff
==============================================================================
--- cfe/trunk/lib/CodeGen/CodeGenModule.cpp (original)
+++ cfe/trunk/lib/CodeGen/CodeGenModule.cpp Thu Jun  1 04:24:36 2017
@@ -1393,8 +1393,8 @@ void CodeGenModule::EmitVTablesOpportuni
   // is not allowed to create new references to things that need to be emitted
   // lazily. Note that it also uses fact that we eagerly emitting RTTI.
 
-  assert(OpportunisticVTables.empty() || shouldOpportunisticallyEmitVTables() &&
-           "Only emit opportunistic vtables with optimizations");
+  assert((OpportunisticVTables.empty() || shouldOpportunisticallyEmitVTables())
+         && "Only emit opportunistic vtables with optimizations");
 
   for (const CXXRecordDecl *RD : OpportunisticVTables) {
     assert(getVTables().isVTableExternal(RD) &&




More information about the cfe-commits mailing list