On Thu, Jun 2, 2011 at 12:38 AM, Maciej Stachowiak <m...@apple.com> wrote: > > Looks to me like these fulfill the requirement of "do we ever use const > pointers to these objects". So the next step is to fix up const member > functions that inappropriately return non-const pointers to objects in the > same tree (or that can otherwise get a back pointer). Make the functions > non-const, then add const variants returning a const pointer if needed. > > I'm curious if there are any clients for const pointers to DOM nodes. >
All functions passed to enclosingNodeOfType in htmlediting.cpp are such clients: Node* enclosingNodeOfType(const Position& p, bool (*nodeIsOfType)(const Node *), EditingBoundaryCrossingRule rule) It takes a boolean function that takes const pointer to a DOM node. It is * critical *that nodeIsOfType does not modify DOM because we use a raw pointer to keep track of the current node when walking up the tree. - Ryosuke
_______________________________________________ webkit-dev mailing list webkit-dev@lists.webkit.org http://lists.webkit.org/mailman/listinfo.cgi/webkit-dev