Changes in directory llvm/include/llvm/ADT:
DenseMap.h updated: 1.18 -> 1.19 --- Log message: Make find return the appropriate iterator/const_iterator --- Diffs of the changes: (+8 -2) DenseMap.h | 10 ++++++++-- 1 files changed, 8 insertions(+), 2 deletions(-) Index: llvm/include/llvm/ADT/DenseMap.h diff -u llvm/include/llvm/ADT/DenseMap.h:1.18 llvm/include/llvm/ADT/DenseMap.h:1.19 --- llvm/include/llvm/ADT/DenseMap.h:1.18 Sat Feb 10 00:34:58 2007 +++ llvm/include/llvm/ADT/DenseMap.h Sat Feb 10 00:58:17 2007 @@ -108,12 +108,18 @@ return LookupBucketFor(Val, TheBucket); } - iterator find(const KeyT &Val) const { + iterator find(const KeyT &Val) { BucketT *TheBucket; if (LookupBucketFor(Val, TheBucket)) return iterator(TheBucket, Buckets+NumBuckets); return end(); } + const_iterator find(const KeyT &Val) const { + BucketT *TheBucket; + if (LookupBucketFor(Val, TheBucket)) + return const_iterator(TheBucket, Buckets+NumBuckets); + return end(); + } bool insert(const std::pair<KeyT, ValueT> &KV) { BucketT *TheBucket; @@ -334,7 +340,7 @@ public: DenseMapConstIterator(const std::pair<KeyT, ValueT> *Pos, const std::pair<KeyT, ValueT> *E) - : DenseMapIterator<KeyT, ValueT>(Pos, E) { + : DenseMapIterator<KeyT, ValueT, KeyInfoT>(Pos, E) { } const std::pair<KeyT, ValueT> &operator*() const { return *this->Ptr; _______________________________________________ llvm-commits mailing list llvm-commits@cs.uiuc.edu http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits