summaryrefslogtreecommitdiffstats
path: root/llvm/lib/IR/Metadata.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'llvm/lib/IR/Metadata.cpp')
-rw-r--r--llvm/lib/IR/Metadata.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/llvm/lib/IR/Metadata.cpp b/llvm/lib/IR/Metadata.cpp
index cbbd808475b..5e41b9f410e 100644
--- a/llvm/lib/IR/Metadata.cpp
+++ b/llvm/lib/IR/Metadata.cpp
@@ -878,7 +878,7 @@ MDNode *MDNode::intersect(MDNode *A, MDNode *B) {
SmallVector<Metadata *, 4> MDs;
for (Metadata *MD : A->operands())
- if (std::find(B->op_begin(), B->op_end(), MD) != B->op_end())
+ if (is_contained(B->operands(), MD))
MDs.push_back(MD);
// FIXME: This preserves long-standing behaviour, but is it really the right
@@ -892,7 +892,7 @@ MDNode *MDNode::getMostGenericAliasScope(MDNode *A, MDNode *B) {
SmallVector<Metadata *, 4> MDs(B->op_begin(), B->op_end());
for (Metadata *MD : A->operands())
- if (std::find(B->op_begin(), B->op_end(), MD) == B->op_end())
+ if (!is_contained(B->operands(), MD))
MDs.push_back(MD);
// FIXME: This preserves long-standing behaviour, but is it really the right
OpenPOWER on IntegriCloud