[NFC] Remove empty check for SingleExpression in Refactoring.cpp findfindConcatenatedExpressions

This commit is contained in:
Luciano Almeida
2020-08-03 09:43:19 -03:00
parent e35d2d355f
commit a31f51d0af

View File

@@ -1846,11 +1846,7 @@ findConcatenatedExpressions(ResolvedRangeInfo Info, ASTContext &Ctx) {
switch (Info.Kind) {
case RangeKind::SingleExpression:
// FIXME: the range info kind should imply non-empty list.
if (!Info.ContainedNodes.empty())
E = Info.ContainedNodes[0].get<Expr*>();
else
return nullptr;
E = Info.ContainedNodes[0].get<Expr*>();
break;
case RangeKind::PartOfExpression:
E = Info.CommonExprParent;