summaryrefslogtreecommitdiff
path: root/lib/Sema
diff options
context:
space:
mode:
Diffstat (limited to 'lib/Sema')
-rw-r--r--lib/Sema/Sema.cpp4
-rw-r--r--lib/Sema/SemaIntrinsic.cpp7
2 files changed, 9 insertions, 2 deletions
diff --git a/lib/Sema/Sema.cpp b/lib/Sema/Sema.cpp
index f36312ede0..fdeacd7ad6 100644
--- a/lib/Sema/Sema.cpp
+++ b/lib/Sema/Sema.cpp
@@ -1065,8 +1065,8 @@ bool Sema::CheckArrayTypeDeclarationCompability(const ArrayType *T, VarDecl *VD)
return false;
for(auto I = T->begin(); I != T->end(); ++I) {
auto Shape = *I;
- if(auto Explicit = dyn_cast<ExplicitShapeSpec>(Shape)) {
- } else {
+ auto Explicit = dyn_cast<ExplicitShapeSpec>(Shape);
+ if(!Explicit) {
// implied
auto Implied = cast<ImpliedShapeSpec>(Shape);
if(!VD->isArgument()) {
diff --git a/lib/Sema/SemaIntrinsic.cpp b/lib/Sema/SemaIntrinsic.cpp
index 34333661b2..c65a79a9c4 100644
--- a/lib/Sema/SemaIntrinsic.cpp
+++ b/lib/Sema/SemaIntrinsic.cpp
@@ -157,6 +157,9 @@ bool Sema::CheckIntrinsicConversionFunc(intrinsic::FunctionKind Function,
CheckIntegerArgument(Item);
ReturnType = Context.CharacterTy;
break;
+
+ default:
+ break;
}
return false;
}
@@ -181,6 +184,8 @@ bool Sema::CheckIntrinsicTruncationFunc(intrinsic::FunctionKind Function,
case FLOOR:
ReturnType = GetUnaryReturnType(Arg, Context.IntegerTy);
break;
+ default:
+ break;
}
return false;
}
@@ -205,6 +210,8 @@ bool Sema::CheckIntrinsicComplexFunc(intrinsic::FunctionKind Function,
case CONJG:
ReturnType = Arg->getType();
break;
+ default:
+ break;
}
return false;
}