diff options
author | Kent Hansen <khansen@trolltech.com> | 2009-09-24 14:35:49 (GMT) |
---|---|---|
committer | Kent Hansen <khansen@trolltech.com> | 2009-09-24 15:36:17 (GMT) |
commit | aabd12223bda6260756ab19430082477d5669c0a (patch) | |
tree | 6ca7a12e627915992cfd0038f6ddd8ee244711f4 /src/script/bridge/qscriptobject.cpp | |
parent | 270c374c178ec5a532d37168b018cd7ebc844558 (diff) | |
download | Qt-aabd12223bda6260756ab19430082477d5669c0a.zip Qt-aabd12223bda6260756ab19430082477d5669c0a.tar.gz Qt-aabd12223bda6260756ab19430082477d5669c0a.tar.bz2 |
Update src/3rdparty/javascriptcore and adapt src/script to the changes.
Reviewed-by: Simon Hausmann
Diffstat (limited to 'src/script/bridge/qscriptobject.cpp')
-rw-r--r-- | src/script/bridge/qscriptobject.cpp | 33 |
1 files changed, 16 insertions, 17 deletions
diff --git a/src/script/bridge/qscriptobject.cpp b/src/script/bridge/qscriptobject.cpp index 0807dc2..0d899f8 100644 --- a/src/script/bridge/qscriptobject.cpp +++ b/src/script/bridge/qscriptobject.cpp @@ -136,13 +136,14 @@ bool QScriptObject::getPropertyAttributes(JSC::ExecState* exec, const JSC::Ident return d->delegate->getPropertyAttributes(this, exec, propertyName, attributes); } -void QScriptObject::getPropertyNames(JSC::ExecState* exec, JSC::PropertyNameArray& propertyNames, unsigned listedAttributes) +void QScriptObject::getOwnPropertyNames(JSC::ExecState* exec, JSC::PropertyNameArray& propertyNames, + bool includeNonEnumerable) { if (!d || !d->delegate) { - JSC::JSObject::getPropertyNames(exec, propertyNames, listedAttributes); + JSC::JSObject::getOwnPropertyNames(exec, propertyNames, includeNonEnumerable); return; } - d->delegate->getPropertyNames(this, exec, propertyNames, listedAttributes); + d->delegate->getOwnPropertyNames(this, exec, propertyNames, includeNonEnumerable); } bool QScriptObject::compareToObject(JSC::ExecState* exec, JSC::JSObject *other) @@ -153,22 +154,20 @@ bool QScriptObject::compareToObject(JSC::ExecState* exec, JSC::JSObject *other) return d->delegate->compareToObject(this, exec, other); } - -void QScriptObject::mark() +void QScriptObject::markChildren(JSC::MarkStack& markStack) { - Q_ASSERT(!marked()); if (!d) d = new Data(); if (d->isMarking) return; QBoolBlocker markBlocker(d->isMarking, true); - if (d && d->data && !d->data.marked()) - d->data.mark(); + if (d && d->data) + markStack.append(d->data); if (!d || !d->delegate) { - JSC::JSObject::mark(); + JSC::JSObject::markChildren(markStack); return; } - d->delegate->mark(this); + d->delegate->markChildren(this, markStack); } JSC::CallType QScriptObject::getCallData(JSC::CallData &data) @@ -235,17 +234,17 @@ bool QScriptObjectDelegate::getPropertyAttributes(const QScriptObject* object, return object->JSC::JSObject::getPropertyAttributes(exec, propertyName, attributes); } -void QScriptObjectDelegate::getPropertyNames(QScriptObject* object, JSC::ExecState* exec, - JSC::PropertyNameArray& propertyNames, - unsigned listedAttributes) +void QScriptObjectDelegate::getOwnPropertyNames(QScriptObject* object, JSC::ExecState* exec, + JSC::PropertyNameArray& propertyNames, + bool includeNonEnumerable) { - object->JSC::JSObject::getPropertyNames(exec, propertyNames, listedAttributes); + object->JSC::JSObject::getOwnPropertyNames(exec, propertyNames, includeNonEnumerable); } -void QScriptObjectDelegate::mark(QScriptObject* object) +void QScriptObjectDelegate::markChildren(QScriptObject* object, JSC::MarkStack& markStack) { - if (!object->marked()) - object->JSC::JSObject::mark(); + // ### should this call the virtual function instead?? + object->JSC::JSObject::markChildren(markStack); } JSC::CallType QScriptObjectDelegate::getCallData(QScriptObject* object, JSC::CallData& data) |