[Webkit-unassigned] [Bug 16401] [GTK] GObject/C DOM binding

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Mon Dec 1 09:03:32 PST 2008


https://bugs.webkit.org/show_bug.cgi?id=16401





------- Comment #100 from mrowe at apple.com  2008-12-01 09:03 PDT -------
(In reply to comment #96)
> Created an attachment (id=25618)
 --> (https://bugs.webkit.org/attachment.cgi?id=25618&action=view) [review]
> I also started checking the use of RefPtr and friends in the patch, and I
> currently have an issue I don't know how to solve. In file GDOMBinding.cpp, a
> number of functions called toGDOM are defined that are intended to wrap core
> DOM objects into GObjects. Since these function actually take ownership of the
> references they receive, they should use PassRefPtr's as parameters. Problem
> is, when I change the parameters, which currently are raw pointers, to
> PassRefPtr, the compiler is not able to resolve the calls any more, complaining
> that they are ambiguous. What should I do in this case? Giving the functions
> different names based on the argument types doesn't look like an option,
> because deciding which one to call (this is mainly done by generated code) is
> not trivial. Any suggestions here would be greatly appreciated.

Can you provide a bit more detail about what you tried here, and what errors
you ran in to?  There will be no need to give each variant of the function a
distinct name.  A simpler workaround if you can't convince the PassRefPtr
approach to work would be to use a raw pointer.  PassRefPtr is a matter of
optimization, not correctness.


-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.



More information about the webkit-unassigned mailing list