diff options
Diffstat (limited to 'llvm/lib/TableGen/SetTheory.cpp')
-rw-r--r-- | llvm/lib/TableGen/SetTheory.cpp | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/llvm/lib/TableGen/SetTheory.cpp b/llvm/lib/TableGen/SetTheory.cpp index 0389bd3ac830..f7ba75243c15 100644 --- a/llvm/lib/TableGen/SetTheory.cpp +++ b/llvm/lib/TableGen/SetTheory.cpp @@ -53,9 +53,9 @@ struct SubOp : public SetTheory::Operator { RecSet Add, Sub; ST.evaluate(*Expr->arg_begin(), Add, Loc); ST.evaluate(Expr->arg_begin() + 1, Expr->arg_end(), Sub, Loc); - for (RecSet::iterator I = Add.begin(), E = Add.end(); I != E; ++I) - if (!Sub.count(*I)) - Elts.insert(*I); + for (const auto &I : Add) + if (!Sub.count(I)) + Elts.insert(I); } }; @@ -69,9 +69,9 @@ struct AndOp : public SetTheory::Operator { RecSet S1, S2; ST.evaluate(Expr->arg_begin()[0], S1, Loc); ST.evaluate(Expr->arg_begin()[1], S2, Loc); - for (RecSet::iterator I = S1.begin(), E = S1.end(); I != E; ++I) - if (S2.count(*I)) - Elts.insert(*I); + for (const auto &I : S1) + if (S2.count(I)) + Elts.insert(I); } }; |