summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorTed Kremenek <kremenek@apple.com>2009-02-23 17:28:16 +0000
committerTed Kremenek <kremenek@apple.com>2009-02-23 17:28:16 +0000
commit638b8b446e7f08d348fe4f3b290c08f6854fc8ba (patch)
tree73427e2e8ad2d385808ba69d68a4a9103668312b /include
parent1c7a666fcef22e75dc675b06444f5a894f54d7be (diff)
downloadllvm-638b8b446e7f08d348fe4f3b290c08f6854fc8ba.tar.gz
llvm-638b8b446e7f08d348fe4f3b290c08f6854fc8ba.tar.bz2
llvm-638b8b446e7f08d348fe4f3b290c08f6854fc8ba.tar.xz
Correctly implement ImmutableMap::getMaxElement() by getting the actual <key, value> pair.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@65327 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include')
-rw-r--r--include/llvm/ADT/ImmutableMap.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/include/llvm/ADT/ImmutableMap.h b/include/llvm/ADT/ImmutableMap.h
index 00d59028aa..52708bc8a1 100644
--- a/include/llvm/ADT/ImmutableMap.h
+++ b/include/llvm/ADT/ImmutableMap.h
@@ -207,7 +207,7 @@ public:
/// which key is the highest in the ordering of keys in the map. This
/// method returns NULL if the map is empty.
value_type* getMaxElement() const {
- return Root ? &(Root->getMaxElement()) : 0;
+ return Root ? &(Root->getMaxElement()->getValue()) : 0;
}
//===--------------------------------------------------===//