[V8] Add custom object compare callback
authorAaron Kennedy <aaron.kennedy@nokia.com>
Thu, 27 Oct 2011 12:40:00 +0000 (13:40 +0100)
committerQt by Nokia <qt-info@nokia.com>
Thu, 1 Mar 2012 11:03:45 +0000 (12:03 +0100)
commit721a248c287cf9534a1715496f8eaa7ed871feb4
tree745adaab4ceedcdc71d1b253eeffa2b95de79da5
parent121ba5bcd134dbc37088e7fadf7dc60a695c7596
[V8] Add custom object compare callback

A global custom object comparison callback can be set with:
    V8::SetUserObjectComparisonCallbackFunction()
When two JSObjects are compared (== or !=), if either one has
the MarkAsUseUserObjectComparison() bit set, the custom comparison
callback is invoked to do the actual comparison.

This is useful when you have "value" objects that you want to
compare as equal, even though they are actually different JS object
instances.

Change-Id: Ifb4074058566062accc2be20d43e3febc1089d13
Reviewed-by: Simon Hausmann <simon.hausmann@nokia.com>
13 files changed:
src/3rdparty/v8/include/v8.h
src/3rdparty/v8/src/api.cc
src/3rdparty/v8/src/arm/code-stubs-arm.cc
src/3rdparty/v8/src/factory.cc
src/3rdparty/v8/src/ia32/code-stubs-ia32.cc
src/3rdparty/v8/src/isolate.cc
src/3rdparty/v8/src/isolate.h
src/3rdparty/v8/src/objects-inl.h
src/3rdparty/v8/src/objects.cc
src/3rdparty/v8/src/objects.h
src/3rdparty/v8/src/runtime.cc
src/3rdparty/v8/src/runtime.h
src/3rdparty/v8/src/x64/code-stubs-x64.cc