summaryrefslogtreecommitdiff
path: root/include/llvm/ADT/UniqueVector.h
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2007-02-05 23:18:32 +0000
committerChris Lattner <sabre@nondot.org>2007-02-05 23:18:32 +0000
commit7b13624b3220ff2a1556668a602939d4f8c9e68a (patch)
tree89e878d4fa3f9f95bcf373f6f4548f0e2d72187e /include/llvm/ADT/UniqueVector.h
parent6a1a28dedde99b2d939c8290d1268cb4938c8183 (diff)
downloadllvm-7b13624b3220ff2a1556668a602939d4f8c9e68a.tar.gz
llvm-7b13624b3220ff2a1556668a602939d4f8c9e68a.tar.bz2
llvm-7b13624b3220ff2a1556668a602939d4f8c9e68a.tar.xz
Const method must use const_iterator.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@33933 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/llvm/ADT/UniqueVector.h')
-rw-r--r--include/llvm/ADT/UniqueVector.h3
1 files changed, 1 insertions, 2 deletions
diff --git a/include/llvm/ADT/UniqueVector.h b/include/llvm/ADT/UniqueVector.h
index 93a9b1c6b5..df9e1e5b2d 100644
--- a/include/llvm/ADT/UniqueVector.h
+++ b/include/llvm/ADT/UniqueVector.h
@@ -1,4 +1,3 @@
-
//===-- llvm/ADT/UniqueVector.h ---------------------------------*- C++ -*-===//
//
// The LLVM Compiler Infrastructure
@@ -56,7 +55,7 @@ public:
/// not found.
unsigned idFor(const T &Entry) const {
// Search for entry in the map.
- typename std::map<T, unsigned>::iterator MI = Map.find(Entry);
+ typename std::map<T, unsigned>::const_iterator MI = Map.find(Entry);
// See if entry exists, if so return ID.
if (MI != Map.end()) return MI->second;