]> granicus.if.org Git - clang/commitdiff
Fix MSVC "not all control paths return a value" warnings. NFCI.
authorSimon Pilgrim <llvm-dev@redking.me.uk>
Wed, 3 Jul 2019 09:54:25 +0000 (09:54 +0000)
committerSimon Pilgrim <llvm-dev@redking.me.uk>
Wed, 3 Jul 2019 09:54:25 +0000 (09:54 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@365012 91177308-0d34-0410-b5e6-96231b3b80d8

lib/AST/ExprConstant.cpp

index a71cc8e123f5901d80cfdaed6ba24cd51c00e380..21cbd6dfa19069adc66b2ecff25c12cd6df432e3 100644 (file)
@@ -5481,6 +5481,7 @@ class APValueToBufferConverter {
     case APValue::LValue:
       llvm_unreachable("LValue subobject in bit_cast?");
     }
+    llvm_unreachable("Unhandled APValue::ValueKind");
   }
 
   bool visitRecord(const APValue &Val, QualType Ty, CharUnits Offset) {
@@ -5749,6 +5750,7 @@ class BufferToAPValueConverter {
     llvm_unreachable("either dependent or not canonical!");
 #include "clang/AST/TypeNodes.def"
     }
+    llvm_unreachable("Unhandled Type::TypeClass");
   }
 
 public: