mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-11-22 10:42:39 +01:00
[tblgen] Fold loop into assert to avoid unused variable warnings. NFCI.
This commit is contained in:
parent
d5252f4ce6
commit
773674bb59
@ -2023,10 +2023,13 @@ void TreePatternNode::InlinePatternFragments(
|
||||
if (ChildAlternatives[i].empty())
|
||||
return;
|
||||
|
||||
for (const auto &NewChild : ChildAlternatives[i])
|
||||
assert((Child->getPredicateCalls().empty() ||
|
||||
NewChild->getPredicateCalls() == Child->getPredicateCalls()) &&
|
||||
"Non-empty child predicate clobbered!");
|
||||
assert(Child->getPredicateCalls().empty() ||
|
||||
llvm::all_of(ChildAlternatives[i],
|
||||
[&](const TreePatternNodePtr &NewChild) {
|
||||
return NewChild->getPredicateCalls() ==
|
||||
Child->getPredicateCalls();
|
||||
}) &&
|
||||
"Non-empty child predicate clobbered!");
|
||||
}
|
||||
|
||||
// The end result is an all-pairs construction of the resultant pattern.
|
||||
|
Loading…
Reference in New Issue
Block a user