WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
126253
Move FilterIterator and IteratorPair to WTF and reimplement HashMap::keys() and HashMap::values() using IteratorPair
https://bugs.webkit.org/show_bug.cgi?id=126253
Summary
Move FilterIterator and IteratorPair to WTF and reimplement HashMap::keys() a...
Sam Weinig
Reported
2013-12-26 22:27:13 PST
Move FilterIterator and IteratorPair to WTF and replement HashMap::keys() and HashMap::values() using IteratorPair
Attachments
Patch
(34.71 KB, patch)
2013-12-26 22:32 PST
,
Sam Weinig
andersca
: review+
Details
Formatted Diff
Diff
View All
Add attachment
proposed patch, testcase, etc.
Sam Weinig
Comment 1
2013-12-26 22:32:57 PST
Created
attachment 220047
[details]
Patch
Sam Weinig
Comment 2
2013-12-26 22:35:22 PST
Anders mentioned he thought this might be a good idea, so I went ahead and did it. I like the cleanup of APIArray::elementsOfType(), but I am bummed I couldn't figure out how to remove the last bit of duplication (the typedef had been duplicated 4 times, and now is down to 2).
Sam Weinig
Comment 3
2013-12-28 13:17:20 PST
Committed
r161114
: <
http://trac.webkit.org/changeset/161114
>
Darin Adler
Comment 4
2013-12-29 22:39:54 PST
Comment on
attachment 220047
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=220047&action=review
> Source/WTF/wtf/IteratorPair.h:44 > Iterator begin() { return m_begin; } > Iterator end() { return m_end; } > > + Iterator begin() const { return m_begin; } > + Iterator end() const { return m_end; }
Why do we need both? Why not just the const ones?
Sam Weinig
Comment 5
2013-12-30 11:02:47 PST
(In reply to
comment #4
)
> (From update of
attachment 220047
[details]
) > View in context:
https://bugs.webkit.org/attachment.cgi?id=220047&action=review
> > > Source/WTF/wtf/IteratorPair.h:44 > > Iterator begin() { return m_begin; } > > Iterator end() { return m_end; } > > > > + Iterator begin() const { return m_begin; } > > + Iterator end() const { return m_end; } > > Why do we need both? Why not just the const ones?
You're right, we don't need the non-const one. I will remove it.
Sam Weinig
Comment 6
2013-12-30 20:17:52 PST
(In reply to
comment #5
)
> (In reply to
comment #4
) > > (From update of
attachment 220047
[details]
[details]) > > View in context:
https://bugs.webkit.org/attachment.cgi?id=220047&action=review
> > > > > Source/WTF/wtf/IteratorPair.h:44 > > > Iterator begin() { return m_begin; } > > > Iterator end() { return m_end; } > > > > > > + Iterator begin() const { return m_begin; } > > > + Iterator end() const { return m_end; } > > > > Why do we need both? Why not just the const ones? > > You're right, we don't need the non-const one. I will remove it.
Fixed in
http://trac.webkit.org/changeset/161162
.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug