Add new JSDependentRetained that allows keeping a JSObject alive as long as another is alive
https://bugs.webkit.org/show_bug.cgi?id=96034

Patch by Elliott Sprehn <esprehn@chromium.org> on 2012-09-11
Reviewed by Geoffrey Garen.

Add new JSDependentRetained (with the same API as V8DependentRetained) that allows keeping
a JSObject alive as long as another is alive. This is useful for keeping callbacks on
wrappers without keeping strong references into the JS heap in C++ which can result in
cycles that create memory leaks.

No new tests needed, this will be used to fix MutationObservers and UndoManager which will have tests.

* GNUmakefile.list.am:
* WebCore.vcproj/WebCore.vcproj:
* WebCore.xcodeproj/project.pbxproj:
* bindings/js/JSDependentRetained.h: Added.
(WebCore):
(JSDependentRetained):
(WebCore::JSDependentRetained::JSDependentRetained):
(WebCore::JSDependentRetained::~JSDependentRetained):
(WebCore::JSDependentRetained::get): Get the JSObject value.
(WebCore::JSDependentRetained::isEmpty): Check if the value is still alive.
(WebCore::JSDependentRetained::retain): Sets the owner of the object, should only be used once.
(WebCore::JSDependentRetained::release):
* bindings/v8/V8DependentRetained.h:
(WebCore::V8DependentRetained::V8DependentRetained):
(WebCore::V8DependentRetained::retain): Added this method so the API for JSC and V8 are identical.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@128249 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Build fixed for http://trac.webkit.org/changeset/128243

Rubber stamped by Stephanie Lewis.

Added missing include file needed by 96422.

* icu/unicode/unorm2.h: Added.


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@128250 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Update bindings test results after http://trac.webkit.org/changeset/128242

* bindings/scripts/test/V8/V8Float64Array.cpp:
(WebCore::V8Float64Array::wrapSlow):
* bindings/scripts/test/V8/V8TestActiveDOMObject.cpp:
(WebCore::V8TestActiveDOMObject::wrapSlow):
* bindings/scripts/test/V8/V8TestCustomNamedGetter.cpp:
(WebCore::V8TestCustomNamedGetter::wrapSlow):
* bindings/scripts/test/V8/V8TestEventConstructor.cpp:
(WebCore::V8TestEventConstructor::wrapSlow):
* bindings/scripts/test/V8/V8TestEventTarget.cpp:
(WebCore::V8TestEventTarget::wrapSlow):
* bindings/scripts/test/V8/V8TestException.cpp:
(WebCore::V8TestException::wrapSlow):
* bindings/scripts/test/V8/V8TestInterface.cpp:
(WebCore::V8TestInterface::wrapSlow):
* bindings/scripts/test/V8/V8TestMediaQueryListListener.cpp:
(WebCore::V8TestMediaQueryListListener::wrapSlow):
* bindings/scripts/test/V8/V8TestNamedConstructor.cpp:
(WebCore::V8TestNamedConstructor::wrapSlow):
* bindings/scripts/test/V8/V8TestNode.cpp:
(WebCore::V8TestNode::wrapSlow):
* bindings/scripts/test/V8/V8TestObj.cpp:
(WebCore::V8TestObj::wrapSlow):
* bindings/scripts/test/V8/V8TestSerializedScriptValueInterface.cpp:
(WebCore::V8TestSerializedScriptValueInterface::wrapSlow):


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@128251 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Build fixed for http://trac.webkit.org/changeset/128243

Unreviewed build fix.

Added missing include file needed by 96422 for C++ ICU APIs.

* icu/unicode/bytestream.h: Added.
* icu/unicode/rep.h: Added.
* icu/unicode/std_string.h: Added.
* icu/unicode/strenum.h: Added.
* icu/unicode/stringpiece.h: Added.
* icu/unicode/unistr.h: Added.
* icu/unicode/uobject.h: Added.


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@128252 268f45cc-cd09-0410-ab3c-d52691b4dbfc