Skip to content

Commit 23f010f

Browse files
authored
[clang] SemaConcept.cpp - fix MSVC "not all control paths return a value" warnings. NFC. (#162060)
1 parent 8303733 commit 23f010f

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

clang/lib/Sema/SemaConcept.cpp

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1049,6 +1049,7 @@ ExprResult ConstraintSatisfactionChecker::Evaluate(
10491049
case NormalizedConstraint::ConstraintKind::Compound:
10501050
return Evaluate(static_cast<const CompoundConstraint &>(Constraint), MLTAL);
10511051
}
1052+
llvm_unreachable("Unknown ConstraintKind enum");
10521053
}
10531054

10541055
static bool CheckConstraintSatisfaction(
@@ -2141,6 +2142,7 @@ bool SubstituteParameterMappings::substitute(NormalizedConstraint &N) {
21412142
return substitute(Compound.getRHS());
21422143
}
21432144
}
2145+
llvm_unreachable("Unknown ConstraintKind enum");
21442146
}
21452147

21462148
} // namespace
@@ -2561,7 +2563,6 @@ FormulaType SubsumptionChecker::Normalize(const NormalizedConstraint &NC) {
25612563
};
25622564

25632565
switch (NC.getKind()) {
2564-
25652566
case NormalizedConstraint::ConstraintKind::Atomic:
25662567
return {{find(&static_cast<const AtomicConstraint &>(NC))}};
25672568

@@ -2601,6 +2602,7 @@ FormulaType SubsumptionChecker::Normalize(const NormalizedConstraint &NC) {
26012602
return Res;
26022603
}
26032604
}
2605+
llvm_unreachable("Unknown ConstraintKind enum");
26042606
}
26052607

26062608
void SubsumptionChecker::AddUniqueClauseToFormula(Formula &F, Clause C) {

0 commit comments

Comments
 (0)