[webkit-dev] Transition to is<>() / downcast<>() is complete
cdumez at apple.com
Mon Oct 20 14:28:39 PDT 2014
I just wanted to let you know that I have just landed the last patch porting the code base to using is<>() / downcast<>().
I have managed to remove the NODE_TYPE_CASTS() / TYPE_CASTS_BASE() macros so there should be no code using it anymore.
If you need to add is<>() / downcast<>() support for a specific class, please use the SPECIALIZE_TYPE_TRAITS_*() macro that is in
wtf/TypeCasts.h. Note however, that the template specializations are already generated for most HTML/SVG/MathML elements by
default so you rarely need manual traits specialization for those.
If you find remaining toXXX() casting functions in the code, please let me know as we don’t want to mix toXXX() and downcast<>().
Do let me know if you have improvement suggestions as well. One that is on my TODO list already is to support is<>(RefPtr), there are
not that many call sites that would benefit from this but it would be nice IMHO.
Chris Dumez - Apple Inc.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the webkit-dev