[webkit-dev] Stop Using Raw Pointers & References in New Code

Darin Adler darin at apple.com
Thu Jan 12 20:37:15 PST 2023


> On Jan 12, 2023, at 9:35 PM, Ryosuke Niwa <rniwa at apple.com> wrote:
> 
> One alternative is to make bar() return RefPtr although that would be a bit heavy handed in the case of trivial function calls like this: document().frame()->ownerElement()

I don’t quite follow. You just said that all arguments including this need to have RefPtr or something like it. What makes it OK to call ownerElement without a RefPtr? What is a “trivial function” and how can we tell which functions are the trivial ones?

— Darin
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-dev/attachments/20230112/18307922/attachment.htm>


More information about the webkit-dev mailing list