Drop [UsePointersEvenForNonNullableObjectArguments] from MutationObserver
authorcdumez@apple.com <cdumez@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 22 Apr 2016 15:59:10 +0000 (15:59 +0000)
committercdumez@apple.com <cdumez@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 22 Apr 2016 15:59:10 +0000 (15:59 +0000)
commitd1665b10d6b56642c20b73c39573333e2441fe32
treef10d909305e6d44c89785e21a1cc69842d748759
parent7975eb5cf66b30d1b826cbd569b6ef95432c68c7
Drop [UsePointersEvenForNonNullableObjectArguments] from MutationObserver
https://bugs.webkit.org/show_bug.cgi?id=156890

Reviewed by Darin Adler.

Source/WebCore:

Drop [UsePointersEvenForNonNullableObjectArguments] from MutationObserver
and clean up / modernize the code a bit. There is not significant Web-
exposed behavior change except that MutationObserver.observe() now throws
a different kind of exception (a TypeError as per Web IDL) when passed in
a null Node.

No new tests, rebaselined existing test.

* bindings/js/JSMutationCallback.cpp:
(WebCore::JSMutationCallback::call):
* bindings/js/JSMutationCallback.h:
* bindings/js/JSMutationObserverCustom.cpp:
(WebCore::constructJSMutationObserver):
* css/PropertySetCSSStyleDeclaration.cpp:
* dom/ChildListMutationScope.cpp:
(WebCore::ChildListMutationAccumulator::enqueueMutationRecord):
* dom/MutationCallback.h:
* dom/MutationObserver.cpp:
(WebCore::MutationObserver::create):
(WebCore::MutationObserver::MutationObserver):
(WebCore::MutationObserver::observe):
(WebCore::MutationObserver::takeRecords):
(WebCore::MutationObserver::enqueueMutationRecord):
(WebCore::MutationObserver::deliver):
(WebCore::MutationObserver::disconnect): Deleted.
* dom/MutationObserver.h:
* dom/MutationObserver.idl:
* dom/MutationObserverInterestGroup.cpp:
(WebCore::MutationObserverInterestGroup::enqueueMutationRecord):
* dom/MutationObserverInterestGroup.h:
* dom/MutationRecord.cpp:
(WebCore::MutationRecord::createChildList):
* dom/MutationRecord.h:

LayoutTests:

Rebaseline now that MutationObserver.observe() throws a TypeError instead
of a NOT_FOUND_ERR when passed a null Node.

* fast/dom/MutationObserver/observe-exceptions-expected.txt:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@199878 268f45cc-cd09-0410-ab3c-d52691b4dbfc
16 files changed:
LayoutTests/ChangeLog
LayoutTests/fast/dom/MutationObserver/observe-exceptions-expected.txt
Source/WebCore/ChangeLog
Source/WebCore/bindings/js/JSMutationCallback.cpp
Source/WebCore/bindings/js/JSMutationCallback.h
Source/WebCore/bindings/js/JSMutationObserverCustom.cpp
Source/WebCore/css/PropertySetCSSStyleDeclaration.cpp
Source/WebCore/dom/ChildListMutationScope.cpp
Source/WebCore/dom/MutationCallback.h
Source/WebCore/dom/MutationObserver.cpp
Source/WebCore/dom/MutationObserver.h
Source/WebCore/dom/MutationObserver.idl
Source/WebCore/dom/MutationObserverInterestGroup.cpp
Source/WebCore/dom/MutationObserverInterestGroup.h
Source/WebCore/dom/MutationRecord.cpp
Source/WebCore/dom/MutationRecord.h