aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--include/clang/AST/Attr.h1
-rw-r--r--include/clang/AST/Stmt.h1
-rw-r--r--lib/AST/ASTContext.cpp7
-rw-r--r--lib/AST/Decl.cpp1
-rw-r--r--lib/AST/DeclBase.cpp2
-rw-r--r--lib/AST/DeclCXX.cpp1
-rw-r--r--lib/AST/DeclObjC.cpp2
-rw-r--r--lib/AST/DeclPrinter.cpp2
-rw-r--r--lib/AST/DeclarationName.cpp3
-rw-r--r--lib/AST/Expr.cpp2
-rw-r--r--lib/AST/ExprConstant.cpp1
-rw-r--r--lib/AST/ItaniumMangle.cpp3
-rw-r--r--lib/AST/MicrosoftMangle.cpp9
-rw-r--r--lib/AST/TemplateBase.cpp2
-rw-r--r--lib/Analysis/FormatString.cpp2
-rw-r--r--lib/CodeGen/CGCall.cpp1
-rw-r--r--lib/CodeGen/CGDebugInfo.cpp4
-rw-r--r--lib/CodeGen/CGExpr.cpp1
-rw-r--r--lib/CodeGen/CGExprAgg.cpp1
-rw-r--r--lib/CodeGen/CGExprComplex.cpp1
-rw-r--r--lib/CodeGen/CGExprConstant.cpp4
-rw-r--r--lib/CodeGen/CGExprScalar.cpp4
-rw-r--r--lib/CodeGen/CGObjCMac.cpp1
-rw-r--r--lib/CodeGen/CGStmt.cpp2
-rw-r--r--lib/CodeGen/CGVTables.cpp3
-rw-r--r--lib/CodeGen/CodeGenAction.cpp1
-rw-r--r--lib/CodeGen/CodeGenTypes.cpp1
-rw-r--r--lib/CodeGen/TargetInfo.cpp1
-rw-r--r--lib/Driver/Action.cpp1
-rw-r--r--lib/Driver/Driver.cpp1
-rw-r--r--lib/Driver/Option.cpp3
-rw-r--r--lib/Driver/Phases.cpp1
-rw-r--r--lib/Index/ASTLocation.cpp1
-rw-r--r--lib/Parse/ParseExprCXX.cpp4
-rw-r--r--lib/Sema/SemaCXXScopeSpec.cpp1
-rw-r--r--lib/Sema/SemaCodeComplete.cpp1
-rw-r--r--lib/Sema/SemaDecl.cpp4
-rw-r--r--lib/Sema/SemaDeclAttr.cpp1
-rw-r--r--lib/Sema/SemaDeclCXX.cpp1
-rw-r--r--lib/Sema/SemaExpr.cpp1
-rw-r--r--lib/Sema/SemaExprCXX.cpp6
-rw-r--r--lib/Sema/SemaOverload.cpp2
-rw-r--r--lib/Sema/SemaStmt.cpp1
-rw-r--r--lib/Sema/SemaTemplate.cpp5
-rw-r--r--lib/Sema/SemaTemplateDeduction.cpp2
-rw-r--r--lib/Sema/SemaTemplateInstantiateDecl.cpp3
-rw-r--r--lib/Sema/SemaType.cpp2
-rw-r--r--lib/Sema/TreeTransform.h3
-rw-r--r--lib/Serialization/ASTReader.cpp2
-rw-r--r--lib/Serialization/ASTReaderDecl.cpp2
-rw-r--r--lib/Serialization/ASTWriterDecl.cpp1
-rw-r--r--lib/StaticAnalyzer/Core/BugReporter.cpp1
-rw-r--r--lib/StaticAnalyzer/Core/CoreEngine.cpp1
-rw-r--r--lib/StaticAnalyzer/Core/ExprEngine.cpp1
-rw-r--r--lib/StaticAnalyzer/Core/ExprEngineC.cpp1
-rw-r--r--lib/StaticAnalyzer/Core/RegionStore.cpp1
-rw-r--r--lib/StaticAnalyzer/Core/SVals.cpp1
-rw-r--r--lib/StaticAnalyzer/Core/SimpleSValBuilder.cpp5
-rw-r--r--lib/StaticAnalyzer/Core/Store.cpp3
-rw-r--r--lib/StaticAnalyzer/Core/SymbolManager.cpp1
-rw-r--r--tools/libclang/CIndexDiagnostic.cpp2
61 files changed, 5 insertions, 125 deletions
diff --git a/include/clang/AST/Attr.h b/include/clang/AST/Attr.h
index c5b564d616..cf2e3c5d25 100644
--- a/include/clang/AST/Attr.h
+++ b/include/clang/AST/Attr.h
@@ -68,7 +68,6 @@ protected:
void* operator new(size_t bytes) throw() {
llvm_unreachable("Attrs cannot be allocated with regular 'new'.");
- return 0;
}
void operator delete(void* data) throw() {
llvm_unreachable("Attrs cannot be released with regular 'delete'.");
diff --git a/include/clang/AST/Stmt.h b/include/clang/AST/Stmt.h
index c186b4896e..3b0edccf02 100644
--- a/include/clang/AST/Stmt.h
+++ b/include/clang/AST/Stmt.h
@@ -108,7 +108,6 @@ public:
protected:
void* operator new(size_t bytes) throw() {
llvm_unreachable("Stmts cannot be allocated with regular 'new'.");
- return 0;
}
void operator delete(void* data) throw() {
llvm_unreachable("Stmts cannot be released with regular 'delete'.");
diff --git a/lib/AST/ASTContext.cpp b/lib/AST/ASTContext.cpp
index de77cb66cf..5e0143dc00 100644
--- a/lib/AST/ASTContext.cpp
+++ b/lib/AST/ASTContext.cpp
@@ -3219,7 +3219,6 @@ ASTContext::getCanonicalTemplateArgument(const TemplateArgument &Arg) const {
// Silence GCC warning
llvm_unreachable("Unhandled template argument kind");
- return TemplateArgument();
}
NestedNameSpecifier *
@@ -4919,7 +4918,6 @@ CanQualType ASTContext::getFromTargetType(unsigned Type) const {
}
llvm_unreachable("Unhandled TargetInfo::IntType value");
- return CanQualType();
}
//===----------------------------------------------------------------------===//
@@ -5749,13 +5747,11 @@ QualType ASTContext::mergeTypes(QualType LHS, QualType RHS,
#define DEPENDENT_TYPE(Class, Base) case Type::Class:
#include "clang/AST/TypeNodes.def"
llvm_unreachable("Non-canonical and dependent types shouldn't get here");
- return QualType();
case Type::LValueReference:
case Type::RValueReference:
case Type::MemberPointer:
llvm_unreachable("C++ should never be in mergeTypes");
- return QualType();
case Type::ObjCInterface:
case Type::IncompleteArray:
@@ -5763,7 +5759,6 @@ QualType ASTContext::mergeTypes(QualType LHS, QualType RHS,
case Type::FunctionProto:
case Type::ExtVector:
llvm_unreachable("Types are eliminated above");
- return QualType();
case Type::Pointer:
{
@@ -6015,7 +6010,6 @@ QualType ASTContext::getCorrespondingUnsignedType(QualType T) {
return UnsignedInt128Ty;
default:
llvm_unreachable("Unexpected signed integer type");
- return QualType();
}
}
@@ -6476,7 +6470,6 @@ MangleContext *ASTContext::createMangleContext() {
return createMicrosoftMangleContext(*this, getDiagnostics());
}
llvm_unreachable("Unsupported ABI");
- return 0;
}
CXXABI::~CXXABI() {}
diff --git a/lib/AST/Decl.cpp b/lib/AST/Decl.cpp
index 2fdb9654b0..a4608eb81c 100644
--- a/lib/AST/Decl.cpp
+++ b/lib/AST/Decl.cpp
@@ -1891,7 +1891,6 @@ FunctionDecl::TemplatedKind FunctionDecl::getTemplatedKind() const {
return TK_DependentFunctionTemplateSpecialization;
llvm_unreachable("Did we miss a TemplateOrSpecialization type?");
- return TK_NonTemplate;
}
FunctionDecl *FunctionDecl::getInstantiatedFromMemberFunction() const {
diff --git a/lib/AST/DeclBase.cpp b/lib/AST/DeclBase.cpp
index d1f8b1c7fd..60fb7025ab 100644
--- a/lib/AST/DeclBase.cpp
+++ b/lib/AST/DeclBase.cpp
@@ -572,7 +572,6 @@ Decl *Decl::castFromDeclContext (const DeclContext *D) {
return static_cast<NAME##Decl*>(const_cast<DeclContext*>(D));
#include "clang/AST/DeclNodes.inc"
llvm_unreachable("a decl that inherits DeclContext isn't handled");
- return 0;
}
}
@@ -592,7 +591,6 @@ DeclContext *Decl::castToDeclContext(const Decl *D) {
return static_cast<NAME##Decl*>(const_cast<Decl*>(D));
#include "clang/AST/DeclNodes.inc"
llvm_unreachable("a decl that inherits DeclContext isn't handled");
- return 0;
}
}
diff --git a/lib/AST/DeclCXX.cpp b/lib/AST/DeclCXX.cpp
index b9af8e3a1f..9addece6f9 100644
--- a/lib/AST/DeclCXX.cpp
+++ b/lib/AST/DeclCXX.cpp
@@ -1694,7 +1694,6 @@ static const char *getAccessName(AccessSpecifier AS) {
default:
case AS_none:
llvm_unreachable("Invalid access specifier!");
- return 0;
case AS_public:
return "public";
case AS_private:
diff --git a/lib/AST/DeclObjC.cpp b/lib/AST/DeclObjC.cpp
index 68177de70d..97f215fb7f 100644
--- a/lib/AST/DeclObjC.cpp
+++ b/lib/AST/DeclObjC.cpp
@@ -550,7 +550,6 @@ ObjCInterfaceDecl *ObjCMethodDecl::getClassInterface() {
assert(!isa<ObjCProtocolDecl>(getDeclContext()) && "It's a protocol method");
llvm_unreachable("unknown method context");
- return 0;
}
//===----------------------------------------------------------------------===//
@@ -782,7 +781,6 @@ const ObjCInterfaceDecl *ObjCIvarDecl::getContainingInterface() const {
case ObjCCategoryImpl:
case ObjCProtocol:
llvm_unreachable("invalid ivar container!");
- return 0;
// Ivars can only appear in class extension categories.
case ObjCCategory: {
diff --git a/lib/AST/DeclPrinter.cpp b/lib/AST/DeclPrinter.cpp
index a17e14053c..8d8ec2f7d2 100644
--- a/lib/AST/DeclPrinter.cpp
+++ b/lib/AST/DeclPrinter.cpp
@@ -192,7 +192,7 @@ void DeclPrinter::ProcessDeclGroup(SmallVectorImpl<Decl*>& Decls) {
void DeclPrinter::Print(AccessSpecifier AS) {
switch(AS) {
- case AS_none: llvm_unreachable("No access specifier!"); break;
+ case AS_none: llvm_unreachable("No access specifier!");
case AS_public: Out << "public"; break;
case AS_protected: Out << "protected"; break;
case AS_private: Out << "private"; break;
diff --git a/lib/AST/DeclarationName.cpp b/lib/AST/DeclarationName.cpp
index 84d4ca94c3..8dfca3e1e7 100644
--- a/lib/AST/DeclarationName.cpp
+++ b/lib/AST/DeclarationName.cpp
@@ -194,7 +194,6 @@ DeclarationName::NameKind DeclarationName::getNameKind() const {
// Can't actually get here.
llvm_unreachable("This should be unreachable!");
- return Identifier;
}
bool DeclarationName::isDependentName() const {
@@ -340,7 +339,6 @@ void *DeclarationName::getFETokenInfoAsVoid() const {
default:
llvm_unreachable("Declaration name has no FETokenInfo");
}
- return 0;
}
void DeclarationName::setFETokenInfo(void *T) {
@@ -622,5 +620,4 @@ SourceLocation DeclarationNameInfo::getEndLoc() const {
return NameLoc;
}
llvm_unreachable("Unexpected declaration name kind");
- return SourceLocation();
}
diff --git a/lib/AST/Expr.cpp b/lib/AST/Expr.cpp
index ba191a8c80..6049f289f8 100644
--- a/lib/AST/Expr.cpp
+++ b/lib/AST/Expr.cpp
@@ -2503,8 +2503,6 @@ Expr::isNullPointerConstant(ASTContext &Ctx,
switch (NPC) {
case NPC_NeverValueDependent:
llvm_unreachable("Unexpected value dependent expression!");
- // If the unthinkable happens, fall through to the safest alternative.
-
case NPC_ValueDependentIsNull:
if (isTypeDependent() || getType()->isIntegralType(Ctx))
return NPCK_ZeroInteger;
diff --git a/lib/AST/ExprConstant.cpp b/lib/AST/ExprConstant.cpp
index 2d4b07021c..2de72f392e 100644
--- a/lib/AST/ExprConstant.cpp
+++ b/lib/AST/ExprConstant.cpp
@@ -389,7 +389,6 @@ public:
RetTy VisitStmt(const Stmt *) {
llvm_unreachable("Expression evaluator should not be called on stmts");
- return DerivedError(0);
}
RetTy VisitExpr(const Expr *E) {
return DerivedError(E);
diff --git a/lib/AST/ItaniumMangle.cpp b/lib/AST/ItaniumMangle.cpp
index ab6ec4e6a1..78f149c2df 100644
--- a/lib/AST/ItaniumMangle.cpp
+++ b/lib/AST/ItaniumMangle.cpp
@@ -1070,7 +1070,6 @@ void CXXNameMangler::mangleUnqualifiedName(const NamedDecl *ND,
case DeclarationName::ObjCOneArgSelector:
case DeclarationName::ObjCMultiArgSelector:
llvm_unreachable("Can't mangle Objective-C selector names here!");
- break;
case DeclarationName::CXXConstructorName:
if (ND == Structor)
@@ -1125,7 +1124,6 @@ void CXXNameMangler::mangleUnqualifiedName(const NamedDecl *ND,
case DeclarationName::CXXUsingDirective:
llvm_unreachable("Can't mangle a using directive name!");
- break;
}
}
@@ -1513,7 +1511,6 @@ CXXNameMangler::mangleOperatorName(OverloadedOperatorKind OO, unsigned Arity) {
case OO_None:
case NUM_OVERLOADED_OPERATORS:
llvm_unreachable("Not an overloaded operator");
- break;
}
}
diff --git a/lib/AST/MicrosoftMangle.cpp b/lib/AST/MicrosoftMangle.cpp
index fd90883bdf..fd99ee189b 100644
--- a/lib/AST/MicrosoftMangle.cpp
+++ b/lib/AST/MicrosoftMangle.cpp
@@ -333,15 +333,12 @@ MicrosoftCXXNameMangler::mangleUnqualifiedName(const NamedDecl *ND,
case DeclarationName::ObjCOneArgSelector:
case DeclarationName::ObjCMultiArgSelector:
llvm_unreachable("Can't mangle Objective-C selector names here!");
- break;
case DeclarationName::CXXConstructorName:
llvm_unreachable("Can't mangle constructors yet!");
- break;
case DeclarationName::CXXDestructorName:
llvm_unreachable("Can't mangle destructors yet!");
- break;
case DeclarationName::CXXConversionFunctionName:
// <operator-name> ::= ?B # (cast)
@@ -356,11 +353,9 @@ MicrosoftCXXNameMangler::mangleUnqualifiedName(const NamedDecl *ND,
case DeclarationName::CXXLiteralOperatorName:
// FIXME: Was this added in VS2010? Does MS even know how to mangle this?
llvm_unreachable("Don't know how to mangle literal operators yet!");
- break;
case DeclarationName::CXXUsingDirective:
llvm_unreachable("Can't mangle a using directive name!");
- break;
}
}
@@ -514,12 +509,10 @@ void MicrosoftCXXNameMangler::mangleOperatorName(OverloadedOperatorKind OO) {
case OO_Conditional:
llvm_unreachable("Don't know how to mangle ?:");
- break;
case OO_None:
case NUM_OVERLOADED_OPERATORS:
llvm_unreachable("Not an overloaded operator");
- break;
}
}
@@ -714,7 +707,6 @@ void MicrosoftCXXNameMangler::mangleType(const BuiltinType *T) {
case BuiltinType::BoundMember:
llvm_unreachable(
"Overloaded and dependent types shouldn't get to name mangling");
- break;
case BuiltinType::ObjCId: Out << "PAUobjc_object@@"; break;
case BuiltinType::ObjCClass: Out << "PAUobjc_class@@"; break;
case BuiltinType::ObjCSel: Out << "PAUobjc_selector@@"; break;
@@ -723,7 +715,6 @@ void MicrosoftCXXNameMangler::mangleType(const BuiltinType *T) {
case BuiltinType::Char32:
case BuiltinType::NullPtr:
llvm_unreachable("Don't know how to mangle this type");
- break;
}
}
diff --git a/lib/AST/TemplateBase.cpp b/lib/AST/TemplateBase.cpp
index b780012557..0c011a8ef0 100644
--- a/lib/AST/TemplateBase.cpp
+++ b/lib/AST/TemplateBase.cpp
@@ -69,7 +69,6 @@ bool TemplateArgument::isDependent() const {
switch (getKind()) {
case Null:
llvm_unreachable("Should not have a NULL template argument");
- return false;
case Type:
return getAsType()->isDependentType();
@@ -108,7 +107,6 @@ bool TemplateArgument::isInstantiationDependent() const {
switch (getKind()) {
case Null:
llvm_unreachable("Should not have a NULL template argument");
- return false;
case Type:
return getAsType()->isInstantiationDependentType();
diff --git a/lib/Analysis/FormatString.cpp b/lib/Analysis/FormatString.cpp
index 3848c2c38f..0f807e21e7 100644
--- a/lib/Analysis/FormatString.cpp
+++ b/lib/Analysis/FormatString.cpp
@@ -210,7 +210,6 @@ bool ArgTypeResult::matchesType(ASTContext &C, QualType argTy) const {
switch (K) {
case InvalidTy:
llvm_unreachable("ArgTypeResult must be valid");
- return true;
case UnknownTy:
return true;
@@ -313,7 +312,6 @@ QualType ArgTypeResult::getRepresentativeType(ASTContext &C) const {
switch (K) {
case InvalidTy:
llvm_unreachable("No representative type for Invalid ArgTypeResult");
- // Fall-through.
case UnknownTy:
return QualType();
case SpecificTy:
diff --git a/lib/CodeGen/CGCall.cpp b/lib/CodeGen/CGCall.cpp
index c246c3cb35..665263d550 100644
--- a/lib/CodeGen/CGCall.cpp
+++ b/lib/CodeGen/CGCall.cpp
@@ -1864,7 +1864,6 @@ RValue CodeGenFunction::EmitCall(const CGFunctionInfo &CallInfo,
}
llvm_unreachable("Unhandled ABIArgInfo::Kind");
- return RValue::get(0);
}
/* VarArg handling */
diff --git a/lib/CodeGen/CGDebugInfo.cpp b/lib/CodeGen/CGDebugInfo.cpp
index 04bf996acd..fed79db9b0 100644
--- a/lib/CodeGen/CGDebugInfo.cpp
+++ b/lib/CodeGen/CGDebugInfo.cpp
@@ -291,16 +291,12 @@ llvm::DIType CGDebugInfo::CreateType(const BuiltinType *BT) {
switch (BT->getKind()) {
case BuiltinType::Dependent:
llvm_unreachable("Unexpected builtin type Dependent");
- return llvm::DIType();
case BuiltinType::Overload:
llvm_unreachable("Unexpected builtin type Overload");
- return llvm::DIType();
case BuiltinType::BoundMember:
llvm_unreachable("Unexpected builtin type BoundMember");
- return llvm::DIType();
case BuiltinType::UnknownAny:
llvm_unreachable("Unexpected builtin type UnknownAny");
- return llvm::DIType();
case BuiltinType::NullPtr:
return DBuilder.
createNullPtrType(BT->getName(CGM.getContext().getLangOptions()));
diff --git a/lib/CodeGen/CGExpr.cpp b/lib/CodeGen/CGExpr.cpp
index f3996c9659..60ce3226a8 100644
--- a/lib/CodeGen/CGExpr.cpp
+++ b/lib/CodeGen/CGExpr.cpp
@@ -1795,7 +1795,6 @@ LValue CodeGenFunction::EmitMemberExpr(const MemberExpr *E) {
return EmitFunctionDeclLValue(*this, E, FD);
llvm_unreachable("Unhandled member declaration!");
- return LValue();
}
LValue CodeGenFunction::EmitLValueForBitfield(llvm::Value *BaseValue,
diff --git a/lib/CodeGen/CGExprAgg.cpp b/lib/CodeGen/CGExprAgg.cpp
index c321faffcf..28c60a05d0 100644
--- a/lib/CodeGen/CGExprAgg.cpp
+++ b/lib/CodeGen/CGExprAgg.cpp
@@ -320,7 +320,6 @@ void AggExprEmitter::VisitCastExpr(CastExpr *E) {
case CK_UncheckedDerivedToBase: {
llvm_unreachable("cannot perform hierarchy conversion in EmitAggExpr: "
"should have been unpacked before we got here");
- break;
}
case CK_GetObjCProperty: {
diff --git a/lib/CodeGen/CGExprComplex.cpp b/lib/CodeGen/CGExprComplex.cpp
index 13c96d4fae..f353fa2523 100644
--- a/lib/CodeGen/CGExprComplex.cpp
+++ b/lib/CodeGen/CGExprComplex.cpp
@@ -104,7 +104,6 @@ public:
ComplexPairTy VisitStmt(Stmt *S) {
S->dump(CGF.getContext().getSourceManager());
llvm_unreachable("Stmt can't have complex result type!");
- return ComplexPairTy();
}
ComplexPairTy VisitExpr(Expr *S);
ComplexPairTy VisitParenExpr(ParenExpr *PE) { return Visit(PE->getSubExpr());}
diff --git a/lib/CodeGen/CGExprConstant.cpp b/lib/CodeGen/CGExprConstant.cpp
index 2de13a4090..1176eb1f9b 100644
--- a/lib/CodeGen/CGExprConstant.cpp
+++ b/lib/CodeGen/CGExprConstant.cpp
@@ -781,9 +781,6 @@ public:
return 0;
llvm_unreachable("Unable to handle InitListExpr");
- // Get rid of control reaches end of void function warning.
- // Not reached.
- return 0;
}
llvm::Constant *VisitCXXConstructExpr(CXXConstructExpr *E) {
@@ -967,7 +964,6 @@ llvm::Constant *CodeGenModule::EmitConstantExpr(const Expr *E,
switch (Result.Val.getKind()) {
case APValue::Uninitialized:
llvm_unreachable("Constant expressions should be initialized.");
- return 0;
case APValue::LValue: {
llvm::Type *DestTy = getTypes().ConvertTypeForMem(DestType);
llvm::Constant *Offset =
diff --git a/lib/CodeGen/CGExprScalar.cpp b/lib/CodeGen/CGExprScalar.cpp
index 90e1232715..264a71403a 100644
--- a/lib/CodeGen/CGExprScalar.cpp
+++ b/lib/CodeGen/CGExprScalar.cpp
@@ -154,7 +154,6 @@ public:
Value *VisitStmt(Stmt *S) {
S->dump(CGF.getContext().getSourceManager());
llvm_unreachable("Stmt can't have complex result type!");
- return 0;
}
Value *VisitExpr(Expr *S);
@@ -1264,10 +1263,8 @@ EmitAddConsiderOverflowBehavior(const UnaryOperator *E,
BinOp.Opcode = BO_Add;
BinOp.E = E;
return EmitOverflowCheckedBinOp(BinOp);
- break;
}
llvm_unreachable("Unknown SignedOverflowBehaviorTy");
- return 0;
}
llvm::Value *
@@ -2756,7 +2753,6 @@ LValue CodeGenFunction::EmitCompoundAssignmentLValue(
case BO_Assign:
case BO_Comma:
llvm_unreachable("Not valid compound assignment operators");
- break;
}
llvm_unreachable("Unhandled compound assignment operator");
diff --git a/lib/CodeGen/CGObjCMac.cpp b/lib/CodeGen/CGObjCMac.cpp
index be574b3efe..1058886e61 100644
--- a/lib/CodeGen/CGObjCMac.cpp
+++ b/lib/CodeGen/CGObjCMac.cpp
@@ -1061,7 +1061,6 @@ public:
/// class of the given name.
virtual llvm::GlobalVariable *GetClassGlobal(const std::string &Name) {
llvm_unreachable("CGObjCMac::GetClassGlobal");
- return 0;
}
};
diff --git a/lib/CodeGen/CGStmt.cpp b/lib/CodeGen/CGStmt.cpp
index 3f986bd1cd..bc34848ccf 100644
--- a/lib/CodeGen/CGStmt.cpp
+++ b/lib/CodeGen/CGStmt.cpp
@@ -139,11 +139,9 @@ void CodeGenFunction::EmitStmt(const Stmt *S) {
case Stmt::ObjCAtCatchStmtClass:
llvm_unreachable(
"@catch statements should be handled by EmitObjCAtTryStmt");
- break;
case Stmt::ObjCAtFinallyStmtClass:
llvm_unreachable(
"@finally statements should be handled by EmitObjCAtTryStmt");
- break;
case Stmt::ObjCAtThrowStmtClass:
EmitObjCAtThrowStmt(cast<ObjCAtThrowStmt>(*S));
break;
diff --git a/lib/CodeGen/CGVTables.cpp b/lib/CodeGen/CGVTables.cpp
index 1a210faa33..f936a9b89d 100644
--- a/lib/CodeGen/CGVTables.cpp
+++ b/lib/CodeGen/CGVTables.cpp
@@ -264,7 +264,6 @@ static BaseOffset ComputeBaseOffset(ASTContext &Context,
if (!const_cast<CXXRecordDecl *>(DerivedRD)->
isDerivedFrom(const_cast<CXXRecordDecl *>(BaseRD), Paths)) {
llvm_unreachable("Class must be derived from the passed in base class!");
- return BaseOffset();
}
return ComputeBaseOffset(Context, DerivedRD, Paths.front());
@@ -701,7 +700,6 @@ CharUnits VCallOffsetMap::getVCallOffsetOffset(const CXXMethodDecl *MD) {
}
llvm_unreachable("Should always find a vcall offset offset!");
- return CharUnits::Zero();
}
/// VCallAndVBaseOffsetBuilder - Class for building vcall and vbase offsets.
@@ -1362,7 +1360,6 @@ VTableBuilder::ComputeThisAdjustmentBaseOffset(BaseSubobject Base,
if (!const_cast<CXXRecordDecl *>(DerivedRD)->
isDerivedFrom(const_cast<CXXRecordDecl *>(BaseRD), Paths)) {
llvm_unreachable("Class must be derived from the passed in base class!");
- return BaseOffset();
}
// We have to go through all the paths, and see which one leads us to the
diff --git a/lib/CodeGen/CodeGenAction.cpp b/lib/CodeGen/CodeGenAction.cpp
index 3251b76742..f266ba9d3e 100644
--- a/lib/CodeGen/CodeGenAction.cpp
+++ b/