[Webkit-unassigned] [Bug 158942] [GTK] Restore webkit_dom_dom_token_list_remove

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Mon Jun 20 14:41:24 PDT 2016


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

Michael Catanzaro <mcatanzaro at igalia.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |mcatanzaro at igalia.com

--- Comment #5 from Michael Catanzaro <mcatanzaro at igalia.com> ---
(In reply to comment #4)
> I skipped variadic functions in Bug 158529 for GObject bindings because I
> thought variadic parameters were not correctly handled.
> 
> "return 1 if $param->isVariadic;" line from CodeGeneratorGObject.pm can be
> removed to restore webkit_dom_dom_token_list_remove and
> webkit_dom_dom_token_list_add functions. I can upload a patch if needed.
> 
> However, the generated code seems to process only the first token passed in
> argument of the function.

Yeah, the generated functions were not variadic. I guess you would have to call the function once for each argument to get the desired effect. The original declaration, present in 2.12, was this:

/**
 * webkit_dom_dom_token_list_remove:
 * @self: A #WebKitDOMDOMTokenList
 * @tokens: A #gchar
 * @error: #GError
 *
 * Stability: Unstable
**/
WEBKIT_API void
webkit_dom_dom_token_list_remove(WebKitDOMDOMTokenList* self, const gchar* tokens, GError** error);

The GError parameter disappeared in trunk a month or two ago. Not a problem, it's unstable API, after all.

Of course, it would be best to generate real variadic functions, but reverting to this form would suffice for Epiphany.

> Which tests should be run to test such kinds of regression?

We have GObject API break tests that would have caught this if it was stable API. We intentionally don't run the tests for the unstable API, because we don't guarantee this API will continue to exist. The problem is that we have two GNOME applications -- Epiphany and Yelp -- that are unfortunately using the unstable API, and Epiphany used this function in particular. The ideal solution would be for them to use only the stable API, but I'm not sure if it's possible.

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.webkit.org/pipermail/webkit-unassigned/attachments/20160620/0680cf77/attachment-0001.html>


More information about the webkit-unassigned mailing list