Bug 80620 - Generated GObject binding code is incorrect for static functions
Summary: Generated GObject binding code is incorrect for static functions
Status: NEW
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebCore JavaScript (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Nobody
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-03-08 11:40 PST by Jon Lee
Modified: 2012-03-08 11:40 PST (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Jon Lee 2012-03-08 11:40:37 PST
In TestObj.idl:

        static void classMethod();
        static long classMethodWithOptional(in [Optional] long arg);

Leads to generated code:

WebKitDOMTestObj.h:

WEBKIT_API void
webkit_dom_test_obj_class_method(WebKitDOMTestObj* self);
WEBKIT_API glong
webkit_dom_test_obj_class_method_with_optional(WebKitDOMTestObj* self, glong arg);

WebKitDOMTestObj.cpp:

void
webkit_dom_test_obj_class_method(WebKitDOMTestObj* self)
{
    g_return_if_fail(self);
    WebCore::JSMainThreadNullState state;
    WebCore::TestObj * item = WebKit::core(self);
    item->classMethod();
}

glong
webkit_dom_test_obj_class_method_with_optional(WebKitDOMTestObj* self, glong arg)
{
    g_return_val_if_fail(self, 0);
    WebCore::JSMainThreadNullState state;
    WebCore::TestObj * item = WebKit::core(self);
    glong res = item->classMethodWithOptional(arg);
    return res;
}