Skip to content

Commit 476890c

Browse files
authored
Merge pull request swiftlang#34312 from CodaFi/just-keep-passing-the-open-windows
Silence a Raft of Warnings from the Windows Build
2 parents 0d8f689 + 0d6a162 commit 476890c

19 files changed

+31
-3
lines changed

include/swift/AST/Decl.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3762,6 +3762,7 @@ struct SelfReferencePosition final {
37623762
case Contravariant:
37633763
return Covariant;
37643764
}
3765+
llvm_unreachable("unhandled self reference position!");
37653766
}
37663767

37673768
explicit operator bool() const { return kind > None; }

include/swift/AST/ForeignErrorConvention.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -198,6 +198,7 @@ class ForeignErrorConvention {
198198
case NonNilError:
199199
return false;
200200
}
201+
llvm_unreachable("unhandled foreign error kind!");
201202
}
202203

203204
bool operator==(ForeignErrorConvention other) const {

include/swift/Demangling/TypeLookupError.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -150,6 +150,7 @@ class TypeLookupError {
150150
delete castContext;
151151
return nullptr;
152152
}
153+
llvm_unreachable("unhandled command!");
153154
};
154155
}
155156

include/swift/Sema/ConstraintSystem.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1907,6 +1907,7 @@ class SolutionApplicationTarget {
19071907
case Kind::patternBinding:
19081908
return patternBinding;
19091909
}
1910+
llvm_unreachable("invalid case label type");
19101911
}
19111912

19121913
VarDecl *getAsUninitializedWrappedVar() const {
@@ -1921,6 +1922,7 @@ class SolutionApplicationTarget {
19211922
case Kind::uninitializedWrappedVar:
19221923
return uninitializedWrappedVar;
19231924
}
1925+
llvm_unreachable("invalid case label type");
19241926
}
19251927

19261928
BraceStmt *getFunctionBody() const {

lib/AST/AutoDiff.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -462,6 +462,7 @@ bool swift::operator==(const TangentPropertyInfo::Error &lhs,
462462
case TangentPropertyInfo::Error::Kind::TangentPropertyWrongType:
463463
return lhs.getType()->isEqual(rhs.getType());
464464
}
465+
llvm_unreachable("unhandled tangent property!");
465466
}
466467

467468
void swift::simple_display(llvm::raw_ostream &os, TangentPropertyInfo info) {

lib/AST/ClangTypeConverter.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -207,6 +207,7 @@ const clang::Type *ClangTypeConverter::getFunctionType(
207207
case SILFunctionType::Representation::Closure:
208208
llvm_unreachable("Expected a C-compatible representation.");
209209
}
210+
llvm_unreachable("unhandled representation!");
210211
}
211212

212213
clang::QualType ClangTypeConverter::convertMemberType(NominalTypeDecl *DC,

lib/AST/TypeCheckRequests.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1497,6 +1497,7 @@ bool ActorIsolation::requiresSubstitution() const {
14971497
case GlobalActor:
14981498
return getGlobalActor()->hasTypeParameter();
14991499
}
1500+
llvm_unreachable("unhandled actor isolation kind!");
15001501
}
15011502

15021503
ActorIsolation ActorIsolation::subst(SubstitutionMap subs) const {
@@ -1509,6 +1510,7 @@ ActorIsolation ActorIsolation::subst(SubstitutionMap subs) const {
15091510
case GlobalActor:
15101511
return forGlobalActor(getGlobalActor().subst(subs));
15111512
}
1513+
llvm_unreachable("unhandled actor isolation kind!");
15121514
}
15131515

15141516
void swift::simple_display(

lib/Driver/DarwinToolChains.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -364,6 +364,7 @@ bool jobMatchesFilter(LinkKind jobKind, BackDeployLibFilter filter) {
364364
case BackDeployLibFilter::all:
365365
return true;
366366
}
367+
llvm_unreachable("unhandled back deploy lib filter!");
367368
}
368369

369370
}

lib/IDE/APIDigesterData.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,7 @@ StringRef swift::ide::api::getDeclKindStr(const DeclKind Value, bool lower) {
5656
}
5757
#include "swift/AST/DeclNodes.def"
5858
}
59+
llvm_unreachable("Unhandled DeclKind in switch.");
5960
} else {
6061
return getDeclKindStrRaw(Value);
6162
}

lib/IRGen/GenCall.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1015,7 +1015,7 @@ namespace {
10151015
llvm::Type *convertVectorType(clang::CanQual<clang::VectorType> type) {
10161016
auto eltTy =
10171017
convertBuiltinType(type->getElementType().castAs<clang::BuiltinType>());
1018-
return llvm::VectorType::get(eltTy, type->getNumElements());
1018+
return llvm::FixedVectorType::get(eltTy, type->getNumElements());
10191019
}
10201020

10211021
llvm::Type *convertBuiltinType(clang::CanQual<clang::BuiltinType> type) {

0 commit comments

Comments
 (0)