<br>On Tuesday, December 31, 2013, Ryosuke Niwa  wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Nice!  Does this also make render objects less dangerous? (For security)<span></span><br>
<br>On Monday, December 30, 2013, Andreas Kling  wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div style="word-wrap:break-word">Sup WebKittens,<div><br></div><div>I’ve just added a “RenderPtr&quot; smart pointer to the rendering code and am in the process of switching code from using raw pointers to this.</div><div>

<br></div><div>Check out the code here: &lt;<a href="https://trac.webkit.org/r161115" target="_blank">https://trac.webkit.org/r161115</a>&gt; (note that I’ve since renamed createRenderObject to createRenderer per Antti’s suggestion.)</div>

<div><br></div><div>It’s basically a clone of OwnPtr that destroys the pointee by calling destroy() on it. This is because RenderObjects currently has a virtual willBeDestroyed() that may depend on still being inside the tree when it executes. I’d like to simplify this eventually, and switch over to std::unique_ptr, but that will require some spooky changes to basic tree operations so I’m deferring it for now.</div>

<div><br></div><div>Cheers and happy new year,</div><div>Kling</div></div></blockquote><br><br>-- <br><div>Ryosuke Niwa</div><div><br></div><br>
</blockquote><br><br>-- <br>- R. Niwa<br>