WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
154691
Should template RefCounter instead of RefCounter::Token
https://bugs.webkit.org/show_bug.cgi?id=154691
Summary
Should template RefCounter instead of RefCounter::Token
Gavin Barraclough
Reported
2016-02-25 13:49:56 PST
My real goal here is to make the counter accurate. Currently returning a Token from token<>() results in ref-count churn. Fixing this either means changing the return value, or improving Token (which will probably mean replacing it with RefPtr). Either way would break the current type checking. Move type tag to RefCount so this can still be enforced.
Attachments
Fix
(26.75 KB, patch)
2016-02-25 13:57 PST
,
Gavin Barraclough
andersca
: review+
Details
Formatted Diff
Diff
View All
Add attachment
proposed patch, testcase, etc.
Gavin Barraclough
Comment 1
2016-02-25 13:57:24 PST
Created
attachment 272235
[details]
Fix
Anders Carlsson
Comment 2
2016-02-25 14:15:33 PST
Comment on
attachment 272235
[details]
Fix View in context:
https://bugs.webkit.org/attachment.cgi?id=272235&action=review
> Source/WTF/wtf/RefCounter.h:172 > +inline typename RefCounter<T>::Token& RefCounter<T>::Token::operator=(const RefCounter<T>::Token& token)
I think this can be inline auto RefCounter<T>::Token::operator=(const RefCounter<T>::Token& token) -> Token&
Gavin Barraclough
Comment 3
2016-02-25 14:58:02 PST
Transmitting file data ................ Committed revision 197132.
Gavin Barraclough
Comment 4
2016-02-25 16:45:48 PST
Speculative windows fix: Transmitting file data .. Committed revision 197146.
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