[Webkit-unassigned] [Bug 84540] JS binding code generator doesn't handle "attribute unsigned long[]" well

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Mon Apr 23 16:24:02 PDT 2012


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


Ryosuke Niwa <rniwa at webkit.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|RESOLVED                    |REOPENED
         Resolution|FIXED                       |




--- Comment #17 from Ryosuke Niwa <rniwa at webkit.org>  2012-04-23 16:23:59 PST ---
I still can't compile:

/Users/rniwa/webkit2/Source/WebCore/bindings/js/JSDOMBinding.h: In function ‘JSC::JSValue WebCore::jsArray(JSC::ExecState*, WebCore::JSDOMGlobalObject*, const WTF::Vector<Value, 0ul>&) [with T = unsigned int]’:
/Users/rniwa/webkit2/WebKitBuild/Release/DerivedSources/WebCore/JSInternals.cpp:224:   instantiated from here
/Users/rniwa/webkit2/Source/WebCore/bindings/js/JSDOMBinding.h:289: error: no matching function for call to ‘getPtr(const unsigned int&)’

    template <typename T>
    JSC::JSValue jsArray(JSC::ExecState* exec, JSDOMGlobalObject* globalObject, const Vector<T>& iterator)
    {
        JSC::MarkedArgumentBuffer list;
        typename Vector<T>::const_iterator end = iterator.end();

        for (typename Vector<T>::const_iterator iter = iterator.begin(); iter != end; ++iter)
            list.append(toJS(exec, globalObject, WTF::getPtr(*iter)));

        return JSC::constructArray(exec, globalObject, list);
    }

JSValue jsInternalsFastMallocStatistics(ExecState* exec, JSValue slotBase, const Identifier&)
{
    JSInternals* castedThis = jsCast<JSInternals*>(asObject(slotBase));
    UNUSED_PARAM(exec);
    Internals* impl = static_cast<Internals*>(castedThis->impl());
    JSValue result = jsArray(exec, castedThis->globalObject(), impl->fastMallocStatistics());
    return result;
}

WTF::getPtr isn't defined for unsigned int :(

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


More information about the webkit-unassigned mailing list