[gardening] Use !empty() over size() > 0

This commit is contained in:
Sho Ikeda
2018-03-08 09:21:09 +09:00
parent f8a9e56957
commit cea6c03eb2
35 changed files with 58 additions and 65 deletions

View File

@@ -286,7 +286,7 @@ bool ObjectOutliner::optimizeObjectAllocation(
ArrayRef<Operand> TailCounts = ARI->getTailAllocatedCounts();
SILType TailType;
unsigned NumTailElems = 0;
if (TailCounts.size() > 0) {
if (!TailCounts.empty()) {
// We only support a single tail allocated array.
if (TailCounts.size() > 1)
return false;