diff options
author | Dan Gohman <gohman@apple.com> | 2008-07-07 17:46:23 +0000 |
---|---|---|
committer | Dan Gohman <gohman@apple.com> | 2008-07-07 17:46:23 +0000 |
commit | 6b345ee9b2833cf1b2f79dc16d06d4060bec36ef (patch) | |
tree | b8faef7c8acf95d5347e03581556fa77218d78a8 /lib/CodeGen/SelectionDAG/LegalizeDAG.cpp | |
parent | aa5044d3ce80a2759a6084911db77dec385a47fc (diff) |
Make DenseMap's insert return a pair, to more closely resemble std::map.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@53177 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/SelectionDAG/LegalizeDAG.cpp')
-rw-r--r-- | lib/CodeGen/SelectionDAG/LegalizeDAG.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp b/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp index 1fa1f3fa2a..5cf637e046 100644 --- a/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp +++ b/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp @@ -115,7 +115,7 @@ class VISIBILITY_HIDDEN SelectionDAGLegalize { LegalizedNodes.insert(std::make_pair(To, To)); } void AddPromotedOperand(SDOperand From, SDOperand To) { - bool isNew = PromotedNodes.insert(std::make_pair(From, To)); + bool isNew = PromotedNodes.insert(std::make_pair(From, To)).second; assert(isNew && "Got into the map somehow?"); // If someone requests legalization of the new node, return itself. LegalizedNodes.insert(std::make_pair(To, To)); @@ -6734,7 +6734,8 @@ void SelectionDAGLegalize::ExpandOp(SDOperand Op, SDOperand &Lo, SDOperand &Hi){ } // Remember in a map if the values will be reused later. - bool isNew = ExpandedNodes.insert(std::make_pair(Op, std::make_pair(Lo, Hi))); + bool isNew = + ExpandedNodes.insert(std::make_pair(Op, std::make_pair(Lo, Hi))).second; assert(isNew && "Value already expanded?!?"); } |