llvm.org GIT mirror llvm / 569b935
Make find return the appropriate iterator/const_iterator git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@34137 91177308-0d34-0410-b5e6-96231b3b80d8 Chris Lattner 13 years ago
1 changed file(s) with 8 addition(s) and 2 deletion(s). Raw diff Collapse all Expand all
107107 return LookupBucketFor(Val, TheBucket);
108108 }
109109
110 iterator find(const KeyT &Val) const {
110 iterator find(const KeyT &Val) {
111111 BucketT *TheBucket;
112112 if (LookupBucketFor(Val, TheBucket))
113113 return iterator(TheBucket, Buckets+NumBuckets);
114 return end();
115 }
116 const_iterator find(const KeyT &Val) const {
117 BucketT *TheBucket;
118 if (LookupBucketFor(Val, TheBucket))
119 return const_iterator(TheBucket, Buckets+NumBuckets);
114120 return end();
115121 }
116122
333339 public:
334340 DenseMapConstIterator(const std::pair *Pos,
335341 const std::pair *E)
336 : DenseMapIterator>(Pos, E) {
342 : DenseMapIterator, KeyInfoT>(Pos, E) {
337343 }
338344 const std::pair &operator*() const {
339345 return *this->Ptr;