Replace 0 and NULL with nullptr in WebCore/dom.
authorhs85.jeong@samsung.com <hs85.jeong@samsung.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 3 Nov 2015 18:24:34 +0000 (18:24 +0000)
committerhs85.jeong@samsung.com <hs85.jeong@samsung.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 3 Nov 2015 18:24:34 +0000 (18:24 +0000)
https://bugs.webkit.org/show_bug.cgi?id=150788

Reviewed by Darin Adler.

No new tests because there is no behavior change.

* dom/Attr.cpp:
(WebCore::Attr::Attr):
(WebCore::Attr::detachFromElementWithValue):
(WebCore::Attr::attachToElement):
* dom/Attr.h:
* dom/CheckedRadioButtons.cpp:
(WebCore::RadioButtonGroup::updateCheckedState):
(WebCore::CheckedRadioButtons::checkedButtonForGroup):
(WebCore::CheckedRadioButtons::isInRequiredGroup):
* dom/ChildListMutationScope.cpp:
(WebCore::ChildListMutationAccumulator::enqueueMutationRecord):
* dom/ContainerNode.cpp:
(WebCore::ContainerNode::removeBetween):
* dom/ContainerNode.h:
(WebCore::ContainerNode::ContainerNode):
* dom/ContainerNodeAlgorithms.cpp:
(WebCore::notifyNodeRemovedFromDocument):
* dom/Document.h:
(WebCore::Document::wellFormed):
(WebCore::Document::scriptRunner):
(WebCore::Document::moduleLoader):
(WebCore::Document::currentScript):
(WebCore::Document::webkitFullscreenElement):
* dom/DocumentOrderedMap.h:
(WebCore::DocumentOrderedMap::MapEntry::MapEntry):
* dom/DocumentParser.cpp:
(WebCore::DocumentParser::detach):
(WebCore::DocumentParser::suspendScheduledTasks):
* dom/Element.cpp:
(WebCore::Element::setAttributeInternal):
(WebCore::Element::shadowRoot):
(WebCore::Element::blur):
(WebCore::Element::beforePseudoElement):
(WebCore::Element::afterPseudoElement):
(WebCore::Element::setBeforePseudoElement):
* dom/Event.cpp:
(WebCore::Event::Event):
* dom/Event.h:
(WebCore::Event::legacyReturnValue):
(WebCore::Event::setLegacyReturnValue):
(WebCore::Event::clipboardData):
* dom/EventContext.cpp:
(WebCore::MouseOrFocusEventContext::MouseOrFocusEventContext):
* dom/EventDispatcher.cpp:
(WebCore::EventPath::lastContextIfExists):
(WebCore::EventDispatcher::dispatchEvent):
* dom/EventListenerMap.cpp:
(WebCore::EventListenerMap::copyEventListenersNotCreatedFromMarkupToTarget):
(WebCore::EventListenerIterator::EventListenerIterator):
* dom/EventListenerMap.h:
* dom/EventTarget.cpp:
(WebCore::EventTarget::fireEventListeners):
* dom/FocusEvent.cpp:
(WebCore::FocusEventInit::FocusEventInit):
* dom/GenericEventQueue.cpp:
(WebCore::GenericEventQueue::enqueueEvent):
* dom/IdTargetObserverRegistry.h:
(WebCore::IdTargetObserverRegistry::IdTargetObserverRegistry):
(WebCore::IdTargetObserverRegistry::notifyObservers):
* dom/IgnoreDestructiveWriteCountIncrementer.h:
(WebCore::IgnoreDestructiveWriteCountIncrementer::IgnoreDestructiveWriteCountIncrementer):
* dom/MessageEvent.cpp:
(WebCore::MessageEvent::MessageEvent):
* dom/MessageEvent.h:
* dom/MessagePort.cpp:
(WebCore::MessagePort::contextDestroyed):
(WebCore::MessagePort::dispatchMessages):
(WebCore::MessagePort::locallyEntangledPort):
(WebCore::MessagePort::disentanglePorts):
* dom/MouseEvent.cpp:
(WebCore::MouseEventInit::MouseEventInit):
(WebCore::MouseEvent::cloneFor):
* dom/MouseEvent.h:
(WebCore::MouseEvent::dataTransfer):
* dom/MouseRelatedEvent.cpp:
(WebCore::MouseRelatedEvent::MouseRelatedEvent):
(WebCore::MouseRelatedEvent::computeRelativePosition):
* dom/MutationEvent.h:
* dom/Node.cpp:
(WebCore::Node::nodeLists):
(WebCore::Node::clearNodeLists):
(WebCore::Node::nonShadowBoundaryParentNode):
(WebCore::Node::parentOrShadowHostElement):
* dom/Node.h:
* dom/NodeRareData.h:
(WebCore::NodeListsNodeData::removeCachedCollection):
(WebCore::NodeListsNodeData::isEmpty):
* dom/PendingScript.cpp:
(WebCore::PendingScript::releaseElementAndClear):
* dom/PopStateEvent.cpp:
(WebCore::PopStateEvent::PopStateEvent):
* dom/Position.h:
(WebCore::Position::deprecatedNode):
(WebCore::Position::document):
(WebCore::Position::rootEditableElement):
* dom/PositionIterator.cpp:
(WebCore::PositionIterator::decrement):
* dom/PositionIterator.h:
(WebCore::PositionIterator::PositionIterator):
* dom/ProcessingInstruction.cpp:
(WebCore::ProcessingInstruction::ProcessingInstruction):
(WebCore::ProcessingInstruction::checkStyleSheet):
(WebCore::ProcessingInstruction::parseStyleSheet):
* dom/ProcessingInstruction.h:
* dom/RangeBoundaryPoint.h:
(WebCore::RangeBoundaryPoint::RangeBoundaryPoint):
* dom/ScriptElement.cpp:
(WebCore::ScriptElement::ScriptElement):
(WebCore::ScriptElement::stopLoadRequest):
(WebCore::ScriptElement::notifyFinished):
(WebCore::ScriptElement::ignoresLoadRequest):
* dom/ScriptedAnimationController.h:
(WebCore::ScriptedAnimationController::create):
(WebCore::ScriptedAnimationController::clearDocumentPointer):
* dom/StyledElement.cpp:
(WebCore::PresentationAttributeCacheKey::PresentationAttributeCacheKey):
(WebCore::StyledElement::addSubresourceAttributeURLs):
(WebCore::StyledElement::rebuildPresentationAttributeStyle):
* dom/StyledElement.h:
(WebCore::StyledElement::additionalPresentationAttributeStyle):
(WebCore::StyledElement::inlineStyle):
* dom/TemplateContentDocumentFragment.h:
* dom/TextEvent.cpp:
(WebCore::TextEvent::TextEvent):
* dom/UIEvent.cpp:
(WebCore::UIEventInit::UIEventInit):
* dom/UserTypingGestureIndicator.cpp:
(WebCore::UserTypingGestureIndicator::UserTypingGestureIndicator):
(WebCore::UserTypingGestureIndicator::~UserTypingGestureIndicator):
* dom/ViewportArguments.cpp:
(WebCore::restrictScaleFactorToInitialScaleIfNotUserScalable):
(WebCore::numericPrefix):
* dom/default/PlatformMessagePortChannel.cpp:
(WebCore::MessagePortChannel::disentangle):
(WebCore::MessagePortChannel::postMessageToRemote):
(WebCore::PlatformMessagePortChannel::PlatformMessagePortChannel):
* dom/default/PlatformMessagePortChannel.h:

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

53 files changed:
Source/WebCore/ChangeLog
Source/WebCore/dom/Attr.cpp
Source/WebCore/dom/Attr.h
Source/WebCore/dom/CheckedRadioButtons.cpp
Source/WebCore/dom/ChildListMutationScope.cpp
Source/WebCore/dom/ContainerNode.cpp
Source/WebCore/dom/ContainerNode.h
Source/WebCore/dom/ContainerNodeAlgorithms.cpp
Source/WebCore/dom/Document.h
Source/WebCore/dom/DocumentOrderedMap.h
Source/WebCore/dom/DocumentParser.cpp
Source/WebCore/dom/Element.cpp
Source/WebCore/dom/Event.cpp
Source/WebCore/dom/Event.h
Source/WebCore/dom/EventContext.cpp
Source/WebCore/dom/EventDispatcher.cpp
Source/WebCore/dom/EventListenerMap.cpp
Source/WebCore/dom/EventListenerMap.h
Source/WebCore/dom/EventTarget.cpp
Source/WebCore/dom/FocusEvent.cpp
Source/WebCore/dom/GenericEventQueue.cpp
Source/WebCore/dom/IdTargetObserverRegistry.h
Source/WebCore/dom/IgnoreDestructiveWriteCountIncrementer.h
Source/WebCore/dom/MessageEvent.cpp
Source/WebCore/dom/MessageEvent.h
Source/WebCore/dom/MessagePort.cpp
Source/WebCore/dom/MouseEvent.cpp
Source/WebCore/dom/MouseEvent.h
Source/WebCore/dom/MouseRelatedEvent.cpp
Source/WebCore/dom/MutationEvent.h
Source/WebCore/dom/Node.cpp
Source/WebCore/dom/Node.h
Source/WebCore/dom/NodeRareData.h
Source/WebCore/dom/PendingScript.cpp
Source/WebCore/dom/PopStateEvent.cpp
Source/WebCore/dom/Position.h
Source/WebCore/dom/PositionIterator.cpp
Source/WebCore/dom/PositionIterator.h
Source/WebCore/dom/ProcessingInstruction.cpp
Source/WebCore/dom/ProcessingInstruction.h
Source/WebCore/dom/RangeBoundaryPoint.h
Source/WebCore/dom/ScriptElement.cpp
Source/WebCore/dom/ScriptElement.h
Source/WebCore/dom/ScriptedAnimationController.h
Source/WebCore/dom/StyledElement.cpp
Source/WebCore/dom/StyledElement.h
Source/WebCore/dom/TemplateContentDocumentFragment.h
Source/WebCore/dom/TextEvent.cpp
Source/WebCore/dom/UIEvent.cpp
Source/WebCore/dom/UserTypingGestureIndicator.cpp
Source/WebCore/dom/ViewportArguments.cpp
Source/WebCore/dom/default/PlatformMessagePortChannel.cpp
Source/WebCore/dom/default/PlatformMessagePortChannel.h

index c7bac58..bb3c190 100644 (file)
@@ -1,3 +1,150 @@
+2015-11-03  Hunseop Jeong  <hs85.jeong@samsung.com>
+
+        Replace 0 and NULL with nullptr in WebCore/dom.
+        https://bugs.webkit.org/show_bug.cgi?id=150788
+
+        Reviewed by Darin Adler.
+
+        No new tests because there is no behavior change.
+
+        * dom/Attr.cpp:
+        (WebCore::Attr::Attr):
+        (WebCore::Attr::detachFromElementWithValue):
+        (WebCore::Attr::attachToElement):
+        * dom/Attr.h:
+        * dom/CheckedRadioButtons.cpp:
+        (WebCore::RadioButtonGroup::updateCheckedState):
+        (WebCore::CheckedRadioButtons::checkedButtonForGroup):
+        (WebCore::CheckedRadioButtons::isInRequiredGroup):
+        * dom/ChildListMutationScope.cpp:
+        (WebCore::ChildListMutationAccumulator::enqueueMutationRecord):
+        * dom/ContainerNode.cpp:
+        (WebCore::ContainerNode::removeBetween):
+        * dom/ContainerNode.h:
+        (WebCore::ContainerNode::ContainerNode):
+        * dom/ContainerNodeAlgorithms.cpp:
+        (WebCore::notifyNodeRemovedFromDocument):
+        * dom/Document.h:
+        (WebCore::Document::wellFormed):
+        (WebCore::Document::scriptRunner):
+        (WebCore::Document::moduleLoader):
+        (WebCore::Document::currentScript):
+        (WebCore::Document::webkitFullscreenElement):
+        * dom/DocumentOrderedMap.h:
+        (WebCore::DocumentOrderedMap::MapEntry::MapEntry):
+        * dom/DocumentParser.cpp:
+        (WebCore::DocumentParser::detach):
+        (WebCore::DocumentParser::suspendScheduledTasks):
+        * dom/Element.cpp:
+        (WebCore::Element::setAttributeInternal):
+        (WebCore::Element::shadowRoot):
+        (WebCore::Element::blur):
+        (WebCore::Element::beforePseudoElement):
+        (WebCore::Element::afterPseudoElement):
+        (WebCore::Element::setBeforePseudoElement):
+        * dom/Event.cpp:
+        (WebCore::Event::Event):
+        * dom/Event.h:
+        (WebCore::Event::legacyReturnValue):
+        (WebCore::Event::setLegacyReturnValue):
+        (WebCore::Event::clipboardData):
+        * dom/EventContext.cpp:
+        (WebCore::MouseOrFocusEventContext::MouseOrFocusEventContext):
+        * dom/EventDispatcher.cpp:
+        (WebCore::EventPath::lastContextIfExists):
+        (WebCore::EventDispatcher::dispatchEvent):
+        * dom/EventListenerMap.cpp:
+        (WebCore::EventListenerMap::copyEventListenersNotCreatedFromMarkupToTarget):
+        (WebCore::EventListenerIterator::EventListenerIterator):
+        * dom/EventListenerMap.h:
+        * dom/EventTarget.cpp:
+        (WebCore::EventTarget::fireEventListeners):
+        * dom/FocusEvent.cpp:
+        (WebCore::FocusEventInit::FocusEventInit):
+        * dom/GenericEventQueue.cpp:
+        (WebCore::GenericEventQueue::enqueueEvent):
+        * dom/IdTargetObserverRegistry.h:
+        (WebCore::IdTargetObserverRegistry::IdTargetObserverRegistry):
+        (WebCore::IdTargetObserverRegistry::notifyObservers):
+        * dom/IgnoreDestructiveWriteCountIncrementer.h:
+        (WebCore::IgnoreDestructiveWriteCountIncrementer::IgnoreDestructiveWriteCountIncrementer):
+        * dom/MessageEvent.cpp:
+        (WebCore::MessageEvent::MessageEvent):
+        * dom/MessageEvent.h:
+        * dom/MessagePort.cpp:
+        (WebCore::MessagePort::contextDestroyed):
+        (WebCore::MessagePort::dispatchMessages):
+        (WebCore::MessagePort::locallyEntangledPort):
+        (WebCore::MessagePort::disentanglePorts):
+        * dom/MouseEvent.cpp:
+        (WebCore::MouseEventInit::MouseEventInit):
+        (WebCore::MouseEvent::cloneFor):
+        * dom/MouseEvent.h:
+        (WebCore::MouseEvent::dataTransfer):
+        * dom/MouseRelatedEvent.cpp:
+        (WebCore::MouseRelatedEvent::MouseRelatedEvent):
+        (WebCore::MouseRelatedEvent::computeRelativePosition):
+        * dom/MutationEvent.h:
+        * dom/Node.cpp:
+        (WebCore::Node::nodeLists):
+        (WebCore::Node::clearNodeLists):
+        (WebCore::Node::nonShadowBoundaryParentNode):
+        (WebCore::Node::parentOrShadowHostElement):
+        * dom/Node.h:
+        * dom/NodeRareData.h:
+        (WebCore::NodeListsNodeData::removeCachedCollection):
+        (WebCore::NodeListsNodeData::isEmpty):
+        * dom/PendingScript.cpp:
+        (WebCore::PendingScript::releaseElementAndClear):
+        * dom/PopStateEvent.cpp:
+        (WebCore::PopStateEvent::PopStateEvent):
+        * dom/Position.h:
+        (WebCore::Position::deprecatedNode):
+        (WebCore::Position::document):
+        (WebCore::Position::rootEditableElement):
+        * dom/PositionIterator.cpp:
+        (WebCore::PositionIterator::decrement):
+        * dom/PositionIterator.h:
+        (WebCore::PositionIterator::PositionIterator):
+        * dom/ProcessingInstruction.cpp:
+        (WebCore::ProcessingInstruction::ProcessingInstruction):
+        (WebCore::ProcessingInstruction::checkStyleSheet):
+        (WebCore::ProcessingInstruction::parseStyleSheet):
+        * dom/ProcessingInstruction.h:
+        * dom/RangeBoundaryPoint.h:
+        (WebCore::RangeBoundaryPoint::RangeBoundaryPoint):
+        * dom/ScriptElement.cpp:
+        (WebCore::ScriptElement::ScriptElement):
+        (WebCore::ScriptElement::stopLoadRequest):
+        (WebCore::ScriptElement::notifyFinished):
+        (WebCore::ScriptElement::ignoresLoadRequest):
+        * dom/ScriptedAnimationController.h:
+        (WebCore::ScriptedAnimationController::create):
+        (WebCore::ScriptedAnimationController::clearDocumentPointer):
+        * dom/StyledElement.cpp:
+        (WebCore::PresentationAttributeCacheKey::PresentationAttributeCacheKey):
+        (WebCore::StyledElement::addSubresourceAttributeURLs):
+        (WebCore::StyledElement::rebuildPresentationAttributeStyle):
+        * dom/StyledElement.h:
+        (WebCore::StyledElement::additionalPresentationAttributeStyle):
+        (WebCore::StyledElement::inlineStyle):
+        * dom/TemplateContentDocumentFragment.h:
+        * dom/TextEvent.cpp:
+        (WebCore::TextEvent::TextEvent):
+        * dom/UIEvent.cpp:
+        (WebCore::UIEventInit::UIEventInit):
+        * dom/UserTypingGestureIndicator.cpp:
+        (WebCore::UserTypingGestureIndicator::UserTypingGestureIndicator):
+        (WebCore::UserTypingGestureIndicator::~UserTypingGestureIndicator):
+        * dom/ViewportArguments.cpp:
+        (WebCore::restrictScaleFactorToInitialScaleIfNotUserScalable):
+        (WebCore::numericPrefix):
+        * dom/default/PlatformMessagePortChannel.cpp:
+        (WebCore::MessagePortChannel::disentangle):
+        (WebCore::MessagePortChannel::postMessageToRemote):
+        (WebCore::PlatformMessagePortChannel::PlatformMessagePortChannel):
+        * dom/default/PlatformMessagePortChannel.h:
+
 2015-11-02  Wenson Hsieh  <wenson_hsieh@apple.com>
 
         Tapping *below* some <input>s can focus them in Mobile Safari
 2015-11-02  Wenson Hsieh  <wenson_hsieh@apple.com>
 
         Tapping *below* some <input>s can focus them in Mobile Safari
index 96d7eed..a0ea437 100644 (file)
@@ -41,16 +41,13 @@ Attr::Attr(Element* element, const QualifiedName& name)
     : ContainerNode(element->document())
     , m_element(element)
     , m_name(name)
     : ContainerNode(element->document())
     , m_element(element)
     , m_name(name)
-    , m_ignoreChildrenChanged(0)
 {
 }
 
 Attr::Attr(Document& document, const QualifiedName& name, const AtomicString& standaloneValue)
     : ContainerNode(document)
 {
 }
 
 Attr::Attr(Document& document, const QualifiedName& name, const AtomicString& standaloneValue)
     : ContainerNode(document)
-    , m_element(0)
     , m_name(name)
     , m_standaloneValue(standaloneValue)
     , m_name(name)
     , m_standaloneValue(standaloneValue)
-    , m_ignoreChildrenChanged(0)
 {
 }
 
 {
 }
 
@@ -209,7 +206,7 @@ void Attr::detachFromElementWithValue(const AtomicString& value)
     ASSERT(m_element);
     ASSERT(m_standaloneValue.isNull());
     m_standaloneValue = value;
     ASSERT(m_element);
     ASSERT(m_standaloneValue.isNull());
     m_standaloneValue = value;
-    m_element = 0;
+    m_element = nullptr;
 }
 
 void Attr::attachToElement(Element* element)
 }
 
 void Attr::attachToElement(Element* element)
index f6f3620..700f8c0 100644 (file)
@@ -91,12 +91,12 @@ private:
 
     // Attr wraps either an element/name, or a name/value pair (when it's a standalone Node.)
     // Note that m_name is always set, but m_element/m_standaloneValue may be null.
 
     // Attr wraps either an element/name, or a name/value pair (when it's a standalone Node.)
     // Note that m_name is always set, but m_element/m_standaloneValue may be null.
-    Element* m_element;
+    Element* m_element { nullptr };
     QualifiedName m_name;
     AtomicString m_standaloneValue;
 
     RefPtr<MutableStyleProperties> m_style;
     QualifiedName m_name;
     AtomicString m_standaloneValue;
 
     RefPtr<MutableStyleProperties> m_style;
-    unsigned m_ignoreChildrenChanged;
+    unsigned m_ignoreChildrenChanged { 0 };
 };
 
 } // namespace WebCore
 };
 
 } // namespace WebCore
index 8305a9e..65f3da9 100644 (file)
@@ -100,7 +100,7 @@ void RadioButtonGroup::updateCheckedState(HTMLInputElement* button)
         setCheckedButton(button);
     else {
         if (m_checkedButton == button)
         setCheckedButton(button);
     else {
         if (m_checkedButton == button)
-            m_checkedButton = 0;
+            m_checkedButton = nullptr;
     }
     if (wasValid != isValid())
         updateValidityForAllButtons();
     }
     if (wasValid != isValid())
         updateValidityForAllButtons();
@@ -221,7 +221,7 @@ HTMLInputElement* CheckedRadioButtons::checkedButtonForGroup(const AtomicString&
         return 0;
     m_nameToGroupMap->checkConsistency();
     RadioButtonGroup* group = m_nameToGroupMap->get(name.impl());
         return 0;
     m_nameToGroupMap->checkConsistency();
     RadioButtonGroup* group = m_nameToGroupMap->get(name.impl());
-    return group ? group->checkedButton() : 0;
+    return group ? group->checkedButton() : nullptr;
 }
 
 bool CheckedRadioButtons::isInRequiredGroup(HTMLInputElement* element) const
 }
 
 bool CheckedRadioButtons::isInRequiredGroup(HTMLInputElement* element) const
index e0ac13e..7e52933 100644 (file)
@@ -130,7 +130,7 @@ void ChildListMutationAccumulator::enqueueMutationRecord()
     RefPtr<NodeList> removedNodes = StaticNodeList::adopt(m_removedNodes);
     RefPtr<MutationRecord> record = MutationRecord::createChildList(m_target, addedNodes.release(), removedNodes.release(), m_previousSibling.release(), m_nextSibling.release());
     m_observers->enqueueMutationRecord(record.release());
     RefPtr<NodeList> removedNodes = StaticNodeList::adopt(m_removedNodes);
     RefPtr<MutationRecord> record = MutationRecord::createChildList(m_target, addedNodes.release(), removedNodes.release(), m_previousSibling.release(), m_nextSibling.release());
     m_observers->enqueueMutationRecord(record.release());
-    m_lastAdded = 0;
+    m_lastAdded = nullptr;
     ASSERT(isEmpty());
 }
 
     ASSERT(isEmpty());
 }
 
index a1abb2e..5c01dab 100644 (file)
@@ -64,7 +64,7 @@ namespace WebCore {
 static void dispatchChildInsertionEvents(Node&);
 static void dispatchChildRemovalEvents(Node&);
 
 static void dispatchChildInsertionEvents(Node&);
 static void dispatchChildRemovalEvents(Node&);
 
-ChildNodesLazySnapshot* ChildNodesLazySnapshot::latestSnapshot = 0;
+ChildNodesLazySnapshot* ChildNodesLazySnapshot::latestSnapshot;
 
 #ifndef NDEBUG
 unsigned NoEventDispatchAssertion::s_count = 0;
 
 #ifndef NDEBUG
 unsigned NoEventDispatchAssertion::s_count = 0;
@@ -584,9 +584,9 @@ void ContainerNode::removeBetween(Node* previousChild, Node* nextChild, Node& ol
     if (m_lastChild == &oldChild)
         m_lastChild = previousChild;
 
     if (m_lastChild == &oldChild)
         m_lastChild = previousChild;
 
-    oldChild.setPreviousSibling(0);
-    oldChild.setNextSibling(0);
-    oldChild.setParentNode(0);
+    oldChild.setPreviousSibling(nullptr);
+    oldChild.setNextSibling(nullptr);
+    oldChild.setParentNode(nullptr);
 
     document().adoptIfNeeded(&oldChild);
 }
 
     document().adoptIfNeeded(&oldChild);
 }
index 599ed35..178f994 100644 (file)
@@ -180,14 +180,12 @@ private:
 
     void willRemoveChild(Node& child);
 
 
     void willRemoveChild(Node& child);
 
-    Node* m_firstChild;
-    Node* m_lastChild;
+    Node* m_firstChild { nullptr };
+    Node* m_lastChild { nullptr };
 };
 
 inline ContainerNode::ContainerNode(Document& document, ConstructionType type)
     : Node(document, type)
 };
 
 inline ContainerNode::ContainerNode(Document& document, ConstructionType type)
     : Node(document, type)
-    , m_firstChild(0)
-    , m_lastChild(0)
 {
 }
 
 {
 }
 
index 8d1cf11..eb7c70e 100644 (file)
@@ -119,7 +119,7 @@ void notifyNodeRemovedFromDocument(ContainerNode& insertionPoint, Node& node)
         return;
 
     if (node.document().cssTarget() == &node)
         return;
 
     if (node.document().cssTarget() == &node)
-        node.document().setCSSTarget(0);
+        node.document().setCSSTarget(nullptr);
 
     if (RefPtr<ShadowRoot> root = downcast<Element>(node).shadowRoot()) {
         if (!node.inDocument() && root->host() == &node)
 
     if (RefPtr<ShadowRoot> root = downcast<Element>(node).shadowRoot()) {
         if (!node.inDocument() && root->host() == &node)
index 1da2e3d..976cda1 100644 (file)
@@ -620,7 +620,7 @@ public:
     
     WEBCORE_EXPORT DocumentLoader* loader() const;
 
     
     WEBCORE_EXPORT DocumentLoader* loader() const;
 
-    void open(Document* ownerDocument = 0);
+    void open(Document* ownerDocument = nullptr);
     void implicitOpen();
 
     // close() is the DOM API document.close()
     void implicitOpen();
 
     // close() is the DOM API document.close()
@@ -634,9 +634,9 @@ public:
 
     void cancelParsing();
 
 
     void cancelParsing();
 
-    void write(const SegmentedString& text, Document* ownerDocument = 0);
-    void write(const String& text, Document* ownerDocument = 0);
-    void writeln(const String& text, Document* ownerDocument = 0);
+    void write(const SegmentedString& text, Document* ownerDocument = nullptr);
+    void write(const String& text, Document* ownerDocument = nullptr);
+    void writeln(const String& text, Document* ownerDocument = nullptr);
 
     bool wellFormed() const { return m_wellFormed; }
 
 
     bool wellFormed() const { return m_wellFormed; }
 
@@ -788,7 +788,7 @@ public:
     void setWindowAttributeEventListener(const AtomicString& eventType, const QualifiedName& attributeName, const AtomicString& value);
     void setWindowAttributeEventListener(const AtomicString& eventType, PassRefPtr<EventListener>);
     EventListener* getWindowAttributeEventListener(const AtomicString& eventType);
     void setWindowAttributeEventListener(const AtomicString& eventType, const QualifiedName& attributeName, const AtomicString& value);
     void setWindowAttributeEventListener(const AtomicString& eventType, PassRefPtr<EventListener>);
     EventListener* getWindowAttributeEventListener(const AtomicString& eventType);
-    WEBCORE_EXPORT void dispatchWindowEvent(PassRefPtr<Event>, PassRefPtr<EventTarget> = 0);
+    WEBCORE_EXPORT void dispatchWindowEvent(PassRefPtr<Event>, PassRefPtr<EventTarget> = nullptr);
     void dispatchWindowLoadEvent();
 
     RefPtr<Event> createEvent(const String& eventType, ExceptionCode&);
     void dispatchWindowLoadEvent();
 
     RefPtr<Event> createEvent(const String& eventType, ExceptionCode&);
@@ -948,7 +948,7 @@ public:
     ScriptRunner* scriptRunner() { return m_scriptRunner.get(); }
     JSModuleLoader* moduleLoader() { return m_moduleLoader.get(); }
 
     ScriptRunner* scriptRunner() { return m_scriptRunner.get(); }
     JSModuleLoader* moduleLoader() { return m_moduleLoader.get(); }
 
-    HTMLScriptElement* currentScript() const { return !m_currentScriptStack.isEmpty() ? m_currentScriptStack.last().get() : 0; }
+    HTMLScriptElement* currentScript() const { return !m_currentScriptStack.isEmpty() ? m_currentScriptStack.last().get() : nullptr; }
     void pushCurrentScript(PassRefPtr<HTMLScriptElement>);
     void popCurrentScript();
 
     void pushCurrentScript(PassRefPtr<HTMLScriptElement>);
     void popCurrentScript();
 
@@ -1135,7 +1135,7 @@ public:
 
     // W3C API
     bool webkitFullscreenEnabled() const;
 
     // W3C API
     bool webkitFullscreenEnabled() const;
-    Element* webkitFullscreenElement() const { return !m_fullScreenElementStack.isEmpty() ? m_fullScreenElementStack.last().get() : 0; }
+    Element* webkitFullscreenElement() const { return !m_fullScreenElementStack.isEmpty() ? m_fullScreenElementStack.last().get() : nullptr; }
     void webkitExitFullscreen();
 #endif
 
     void webkitExitFullscreen();
 #endif
 
@@ -1346,7 +1346,7 @@ private:
     virtual void refScriptExecutionContext() override final { ref(); }
     virtual void derefScriptExecutionContext() override final { deref(); }
 
     virtual void refScriptExecutionContext() override final { ref(); }
     virtual void derefScriptExecutionContext() override final { deref(); }
 
-    virtual void addMessage(MessageSource, MessageLevel, const String& message, const String& sourceURL, unsigned lineNumber, unsigned columnNumber, RefPtr<Inspector::ScriptCallStack>&&, JSC::ExecState* = 0, unsigned long requestIdentifier = 0) override final;
+    virtual void addMessage(MessageSource, MessageLevel, const String& message, const String& sourceURL, unsigned lineNumber, unsigned columnNumber, RefPtr<Inspector::ScriptCallStack>&&, JSC::ExecState* = nullptr, unsigned long requestIdentifier = 0) override final;
 
     virtual double minimumTimerInterval() const override final;
 
 
     virtual double minimumTimerInterval() const override final;
 
index c39d06f..720555b 100644 (file)
@@ -73,17 +73,14 @@ private:
     Element* get(const AtomicStringImpl&, const TreeScope&, const KeyMatchingFunction&) const;
 
     struct MapEntry {
     Element* get(const AtomicStringImpl&, const TreeScope&, const KeyMatchingFunction&) const;
 
     struct MapEntry {
-        MapEntry()
-            : element(0)
-            , count(0)
-        { }
+        MapEntry() { }
         explicit MapEntry(Element* firstElement)
             : element(firstElement)
             , count(1)
         { }
 
         explicit MapEntry(Element* firstElement)
             : element(firstElement)
             , count(1)
         { }
 
-        Element* element;
-        unsigned count;
+        Element* element { nullptr };
+        unsigned count { 0 };
         Vector<Element*> orderedList;
 #if !ASSERT_DISABLED || ENABLE(SECURITY_ASSERTIONS)
         HashSet<Element*> registeredElements;
         Vector<Element*> orderedList;
 #if !ASSERT_DISABLED || ENABLE(SECURITY_ASSERTIONS)
         HashSet<Element*> registeredElements;
index 9dca08f..6bcfb00 100644 (file)
@@ -64,7 +64,7 @@ void DocumentParser::stopParsing()
 void DocumentParser::detach()
 {
     m_state = DetachedState;
 void DocumentParser::detach()
 {
     m_state = DetachedState;
-    m_document = 0;
+    m_document = nullptr;
 }
 
 void DocumentParser::suspendScheduledTasks()
 }
 
 void DocumentParser::suspendScheduledTasks()
index 8966b87..98a610f 100644 (file)
@@ -1181,7 +1181,7 @@ inline void Element::setAttributeInternal(unsigned index, const QualifiedName& n
         // If there is an Attr node hooked to this attribute, the Attr::setValue() call below
         // will write into the ElementData.
         // FIXME: Refactor this so it makes some sense.
         // If there is an Attr node hooked to this attribute, the Attr::setValue() call below
         // will write into the ElementData.
         // FIXME: Refactor this so it makes some sense.
-        if (RefPtr<Attr> attrNode = inSynchronizationOfLazyAttribute ? 0 : attrIfExists(attributeName))
+        if (RefPtr<Attr> attrNode = inSynchronizationOfLazyAttribute ? nullptr : attrIfExists(attributeName))
             attrNode->setValue(newValue);
         else
             ensureUniqueElementData().attributeAt(index).setValue(newValue);
             attrNode->setValue(newValue);
         else
             ensureUniqueElementData().attributeAt(index).setValue(newValue);
@@ -1628,7 +1628,7 @@ void Element::unregisterNamedFlowContentElement()
 
 ShadowRoot* Element::shadowRoot() const
 {
 
 ShadowRoot* Element::shadowRoot() const
 {
-    return hasRareData() ? elementRareData()->shadowRoot() : 0;
+    return hasRareData() ? elementRareData()->shadowRoot() : nullptr;
 }
 
 
 }
 
 
@@ -2279,7 +2279,7 @@ void Element::blur()
         if (Frame* frame = document().frame())
             frame->page()->focusController().setFocusedElement(0, frame);
         else
         if (Frame* frame = document().frame())
             frame->page()->focusController().setFocusedElement(0, frame);
         else
-            document().setFocusedElement(0);
+            document().setFocusedElement(nullptr);
     }
 }
 
     }
 }
 
@@ -2670,12 +2670,12 @@ void Element::normalizeAttributes()
 
 PseudoElement* Element::beforePseudoElement() const
 {
 
 PseudoElement* Element::beforePseudoElement() const
 {
-    return hasRareData() ? elementRareData()->beforePseudoElement() : 0;
+    return hasRareData() ? elementRareData()->beforePseudoElement() : nullptr;
 }
 
 PseudoElement* Element::afterPseudoElement() const
 {
 }
 
 PseudoElement* Element::afterPseudoElement() const
 {
-    return hasRareData() ? elementRareData()->afterPseudoElement() : 0;
+    return hasRareData() ? elementRareData()->afterPseudoElement() : nullptr;
 }
 
 void Element::setBeforePseudoElement(Ref<PseudoElement>&& element)
 }
 
 void Element::setBeforePseudoElement(Ref<PseudoElement>&& element)
index 0ed4db5..596dd85 100644 (file)
@@ -42,16 +42,7 @@ EventInit::EventInit(bool b, bool c)
 }
 
 Event::Event()
 }
 
 Event::Event()
-    : m_canBubble(false)
-    , m_cancelable(false)
-    , m_propagationStopped(false)
-    , m_immediatePropagationStopped(false)
-    , m_defaultPrevented(false)
-    , m_defaultHandled(false)
-    , m_cancelBubble(false)
-    , m_eventPhase(0)
-    , m_currentTarget(0)
-    , m_createTime(convertSecondsToDOMTimeStamp(currentTime()))
+    : m_createTime(convertSecondsToDOMTimeStamp(currentTime()))
 {
 }
 
 {
 }
 
@@ -60,13 +51,6 @@ Event::Event(const AtomicString& eventType, bool canBubbleArg, bool cancelableAr
     , m_type(eventType)
     , m_canBubble(canBubbleArg)
     , m_cancelable(cancelableArg)
     , m_type(eventType)
     , m_canBubble(canBubbleArg)
     , m_cancelable(cancelableArg)
-    , m_propagationStopped(false)
-    , m_immediatePropagationStopped(false)
-    , m_defaultPrevented(false)
-    , m_defaultHandled(false)
-    , m_cancelBubble(false)
-    , m_eventPhase(0)
-    , m_currentTarget(0)
     , m_createTime(convertSecondsToDOMTimeStamp(currentTime()))
 {
 }
     , m_createTime(convertSecondsToDOMTimeStamp(currentTime()))
 {
 }
@@ -76,13 +60,6 @@ Event::Event(const AtomicString& eventType, bool canBubbleArg, bool cancelableAr
     , m_type(eventType)
     , m_canBubble(canBubbleArg)
     , m_cancelable(cancelableArg)
     , m_type(eventType)
     , m_canBubble(canBubbleArg)
     , m_cancelable(cancelableArg)
-    , m_propagationStopped(false)
-    , m_immediatePropagationStopped(false)
-    , m_defaultPrevented(false)
-    , m_defaultHandled(false)
-    , m_cancelBubble(false)
-    , m_eventPhase(0)
-    , m_currentTarget(0)
     , m_createTime(convertSecondsToDOMTimeStamp(timestamp))
 {
 }
     , m_createTime(convertSecondsToDOMTimeStamp(timestamp))
 {
 }
@@ -92,13 +69,6 @@ Event::Event(const AtomicString& eventType, const EventInit& initializer)
     , m_type(eventType)
     , m_canBubble(initializer.bubbles)
     , m_cancelable(initializer.cancelable)
     , m_type(eventType)
     , m_canBubble(initializer.bubbles)
     , m_cancelable(initializer.cancelable)
-    , m_propagationStopped(false)
-    , m_immediatePropagationStopped(false)
-    , m_defaultPrevented(false)
-    , m_defaultHandled(false)
-    , m_cancelBubble(false)
-    , m_eventPhase(0)
-    , m_currentTarget(0)
     , m_createTime(convertSecondsToDOMTimeStamp(currentTime()))
 {
 }
     , m_createTime(convertSecondsToDOMTimeStamp(currentTime()))
 {
 }
index 74f855a..09e778d 100644 (file)
@@ -127,7 +127,7 @@ public:
     bool legacyReturnValue() const { return !defaultPrevented(); }
     void setLegacyReturnValue(bool returnValue) { setDefaultPrevented(!returnValue); }
 
     bool legacyReturnValue() const { return !defaultPrevented(); }
     void setLegacyReturnValue(bool returnValue) { setDefaultPrevented(!returnValue); }
 
-    DataTransfer* clipboardData() const { return isClipboardEvent() ? internalDataTransfer() : 0; }
+    DataTransfer* clipboardData() const { return isClipboardEvent() ? internalDataTransfer() : nullptr; }
 
     virtual EventInterface eventInterface() const;
 
 
     virtual EventInterface eventInterface() const;
 
@@ -191,17 +191,17 @@ protected:
 private:
     bool m_isInitialized { false };
     AtomicString m_type;
 private:
     bool m_isInitialized { false };
     AtomicString m_type;
-    bool m_canBubble;
-    bool m_cancelable;
+    bool m_canBubble { false };
+    bool m_cancelable { false };
 
 
-    bool m_propagationStopped;
-    bool m_immediatePropagationStopped;
-    bool m_defaultPrevented;
-    bool m_defaultHandled;
-    bool m_cancelBubble;
+    bool m_propagationStopped { false };
+    bool m_immediatePropagationStopped { false };
+    bool m_defaultPrevented { false };
+    bool m_defaultHandled { false };
+    bool m_cancelBubble { false };
 
 
-    unsigned short m_eventPhase;
-    EventTarget* m_currentTarget;
+    unsigned short m_eventPhase { 0 };
+    EventTarget* m_currentTarget { nullptr };
     RefPtr<EventTarget> m_target;
     DOMTimeStamp m_createTime;
 
     RefPtr<EventTarget> m_target;
     DOMTimeStamp m_createTime;
 
index 6dffc6f..b72eaff 100644 (file)
@@ -66,7 +66,6 @@ bool EventContext::isTouchEventContext() const
 
 MouseOrFocusEventContext::MouseOrFocusEventContext(PassRefPtr<Node> node, PassRefPtr<EventTarget> currentTarget, PassRefPtr<EventTarget> target)
     : EventContext(node, currentTarget, target)
 
 MouseOrFocusEventContext::MouseOrFocusEventContext(PassRefPtr<Node> node, PassRefPtr<EventTarget> currentTarget, PassRefPtr<EventTarget> target)
     : EventContext(node, currentTarget, target)
-    , m_relatedTarget(0)
 {
 }
 
 {
 }
 
index 28e3a49..2bdc350 100644 (file)
@@ -92,7 +92,7 @@ public:
 
     bool hasEventListeners(const AtomicString& eventType) const;
 
 
     bool hasEventListeners(const AtomicString& eventType) const;
 
-    EventContext* lastContextIfExists() { return m_path.isEmpty() ? 0 : m_path.last().get(); }
+    EventContext* lastContextIfExists() { return m_path.isEmpty() ? nullptr : m_path.last().get(); }
 
 private:
 #if ENABLE(TOUCH_EVENTS) && !PLATFORM(IOS)
 
 private:
 #if ENABLE(TOUCH_EVENTS) && !PLATFORM(IOS)
@@ -355,7 +355,7 @@ bool EventDispatcher::dispatchEvent(Node* origin, PassRefPtr<Event> prpEvent)
     // Ensure that after event dispatch, the event's target object is the
     // outermost shadow DOM boundary.
     event->setTarget(windowEventContext.target());
     // Ensure that after event dispatch, the event's target object is the
     // outermost shadow DOM boundary.
     event->setTarget(windowEventContext.target());
-    event->setCurrentTarget(0);
+    event->setCurrentTarget(nullptr);
 
     return !event->defaultPrevented();
 }
 
     return !event->defaultPrevented();
 }
index 36b7724..f197c20 100644 (file)
@@ -197,17 +197,7 @@ void EventListenerMap::copyEventListenersNotCreatedFromMarkupToTarget(EventTarge
         copyListenersNotCreatedFromMarkupToTarget(entry.first, entry.second.get(), target);
 }
 
         copyListenersNotCreatedFromMarkupToTarget(entry.first, entry.second.get(), target);
 }
 
-EventListenerIterator::EventListenerIterator()
-    : m_map(0)
-    , m_entryIndex(0)
-    , m_index(0)
-{
-}
-
 EventListenerIterator::EventListenerIterator(EventTarget* target)
 EventListenerIterator::EventListenerIterator(EventTarget* target)
-    : m_map(0)
-    , m_entryIndex(0)
-    , m_index(0)
 {
     ASSERT(target);
     EventTargetData* data = target->eventTargetData();
 {
     ASSERT(target);
     EventTargetData* data = target->eventTargetData();
index da2bb4d..89ff666 100644 (file)
@@ -86,9 +86,9 @@ public:
     EventListener* nextListener();
 
 private:
     EventListener* nextListener();
 
 private:
-    EventListenerMap* m_map;
-    unsigned m_entryIndex;
-    unsigned m_index;
+    EventListenerMap* m_map { nullptr };
+    unsigned m_entryIndex { 0 };
+    unsigned m_index { 0 };
 };
 
 #ifdef NDEBUG
 };
 
 #ifdef NDEBUG
index cfc4a3a..762a6a5 100644 (file)
@@ -195,7 +195,7 @@ bool EventTarget::fireEventListeners(Event* event)
     if (!d)
         return true;
 
     if (!d)
         return true;
 
-    EventListenerVector* legacyListenersVector = 0;
+    EventListenerVector* legacyListenersVector = nullptr;
     const AtomicString& legacyTypeName = legacyType(event);
     if (!legacyTypeName.isEmpty())
         legacyListenersVector = d->eventListenerMap.find(legacyTypeName);
     const AtomicString& legacyTypeName = legacyType(event);
     if (!legacyTypeName.isEmpty())
         legacyListenersVector = d->eventListenerMap.find(legacyTypeName);
index 4dd748c..9f2089e 100644 (file)
@@ -31,7 +31,6 @@
 namespace WebCore {
 
 FocusEventInit::FocusEventInit()
 namespace WebCore {
 
 FocusEventInit::FocusEventInit()
-    : relatedTarget(0)
 {
 }
 
 {
 }
 
index 21a59a2..72dd0fe 100644 (file)
@@ -51,7 +51,7 @@ void GenericEventQueue::enqueueEvent(PassRefPtr<Event> event)
         return;
 
     if (event->target() == &m_owner)
         return;
 
     if (event->target() == &m_owner)
-        event->setTarget(0);
+        event->setTarget(nullptr);
 
     m_pendingEvents.append(event);
 
 
     m_pendingEvents.append(event);
 
index 20ccc9b..3be05d0 100644 (file)
@@ -40,9 +40,7 @@ class IdTargetObserverRegistry {
     WTF_MAKE_FAST_ALLOCATED;
     friend class IdTargetObserver;
 public:
     WTF_MAKE_FAST_ALLOCATED;
     friend class IdTargetObserver;
 public:
-    IdTargetObserverRegistry()
-        : m_notifyingObserversInSet(0)
-    { }
+    IdTargetObserverRegistry() { }
 
     void notifyObservers(const AtomicString& id);
     void notifyObservers(const AtomicStringImpl& id);
 
     void notifyObservers(const AtomicString& id);
     void notifyObservers(const AtomicStringImpl& id);
@@ -55,7 +53,7 @@ private:
     typedef HashSet<IdTargetObserver*> ObserverSet;
     typedef HashMap<const AtomicStringImpl*, std::unique_ptr<ObserverSet>> IdToObserverSetMap;
     IdToObserverSetMap m_registry;
     typedef HashSet<IdTargetObserver*> ObserverSet;
     typedef HashMap<const AtomicStringImpl*, std::unique_ptr<ObserverSet>> IdToObserverSetMap;
     IdToObserverSetMap m_registry;
-    ObserverSet* m_notifyingObserversInSet;
+    ObserverSet* m_notifyingObserversInSet { nullptr };
 };
 
 inline void IdTargetObserverRegistry::notifyObservers(const AtomicString& id)
 };
 
 inline void IdTargetObserverRegistry::notifyObservers(const AtomicString& id)
index 26f7fd0..054ebd9 100644 (file)
@@ -34,7 +34,7 @@ class IgnoreDestructiveWriteCountIncrementer {
     WTF_MAKE_NONCOPYABLE(IgnoreDestructiveWriteCountIncrementer);
 public:
     explicit IgnoreDestructiveWriteCountIncrementer(Document* document)
     WTF_MAKE_NONCOPYABLE(IgnoreDestructiveWriteCountIncrementer);
 public:
     explicit IgnoreDestructiveWriteCountIncrementer(Document* document)
-        : m_count(document ? &document->m_ignoreDestructiveWriteCount : 0)
+        : m_count(document ? &document->m_ignoreDestructiveWriteCount : nullptr)
     {
         if (!m_count)
             return;
     {
         if (!m_count)
             return;
index d3c34bf..5de3259 100644 (file)
@@ -52,7 +52,7 @@ MessageEvent::MessageEvent(const AtomicString& type, const MessageEventInit& ini
     , m_dataAsScriptValue(initializer.data)
     , m_origin(initializer.origin)
     , m_lastEventId(initializer.lastEventId)
     , m_dataAsScriptValue(initializer.data)
     , m_origin(initializer.origin)
     , m_lastEventId(initializer.lastEventId)
-    , m_source(isValidSource(initializer.source.get()) ? initializer.source : 0)
+    , m_source(isValidSource(initializer.source.get()) ? initializer.source : nullptr)
     , m_ports(std::make_unique<MessagePortArray>(initializer.ports))
 {
 }
     , m_ports(std::make_unique<MessagePortArray>(initializer.ports))
 {
 }
index 207a72e..e4258e1 100644 (file)
@@ -57,11 +57,11 @@ public:
     {
         return adoptRef(*new MessageEvent);
     }
     {
         return adoptRef(*new MessageEvent);
     }
-    static Ref<MessageEvent> create(std::unique_ptr<MessagePortArray> ports, const Deprecated::ScriptValue& data = Deprecated::ScriptValue(), const String& origin = String(), const String& lastEventId = String(), PassRefPtr<EventTarget> source = 0)
+    static Ref<MessageEvent> create(std::unique_ptr<MessagePortArray> ports, const Deprecated::ScriptValue& data = Deprecated::ScriptValue(), const String& origin = String(), const String& lastEventId = String(), PassRefPtr<EventTarget> source = nullptr)
     {
         return adoptRef(*new MessageEvent(data, origin, lastEventId, source, WTF::move(ports)));
     }
     {
         return adoptRef(*new MessageEvent(data, origin, lastEventId, source, WTF::move(ports)));
     }
-    static Ref<MessageEvent> create(std::unique_ptr<MessagePortArray> ports, PassRefPtr<SerializedScriptValue> data, const String& origin = String(), const String& lastEventId = String(), PassRefPtr<EventTarget> source = 0)
+    static Ref<MessageEvent> create(std::unique_ptr<MessagePortArray> ports, PassRefPtr<SerializedScriptValue> data, const String& origin = String(), const String& lastEventId = String(), PassRefPtr<EventTarget> source = nullptr)
     {
         return adoptRef(*new MessageEvent(data, origin, lastEventId, source, WTF::move(ports)));
     }
     {
         return adoptRef(*new MessageEvent(data, origin, lastEventId, source, WTF::move(ports)));
     }
index 8af307f..c325684 100644 (file)
@@ -142,7 +142,7 @@ void MessagePort::contextDestroyed()
     // Must be closed before blowing away the cached context, to ensure that we get no more calls to messageAvailable().
     // ScriptExecutionContext::closeMessagePorts() takes care of that.
     ASSERT(m_closed);
     // Must be closed before blowing away the cached context, to ensure that we get no more calls to messageAvailable().
     // ScriptExecutionContext::closeMessagePorts() takes care of that.
     ASSERT(m_closed);
-    m_scriptExecutionContext = 0;
+    m_scriptExecutionContext = nullptr;
 }
 
 void MessagePort::dispatchMessages()
 }
 
 void MessagePort::dispatchMessages()
@@ -179,7 +179,7 @@ bool MessagePort::hasPendingActivity()
 
 MessagePort* MessagePort::locallyEntangledPort()
 {
 
 MessagePort* MessagePort::locallyEntangledPort()
 {
-    return m_entangledChannel ? m_entangledChannel->locallyEntangledPort(m_scriptExecutionContext) : 0;
+    return m_entangledChannel ? m_entangledChannel->locallyEntangledPort(m_scriptExecutionContext) : nullptr;
 }
 
 std::unique_ptr<MessagePortChannelArray> MessagePort::disentanglePorts(const MessagePortArray* ports, ExceptionCode& ec)
 }
 
 std::unique_ptr<MessagePortChannelArray> MessagePort::disentanglePorts(const MessagePortArray* ports, ExceptionCode& ec)
index 9b7266a..52c0968 100644 (file)
@@ -43,7 +43,6 @@ MouseEventInit::MouseEventInit()
     , shiftKey(false)
     , metaKey(false)
     , button(0)
     , shiftKey(false)
     , metaKey(false)
     , button(0)
-    , relatedTarget(0)
 {
 }
 
 {
 }
 
@@ -243,7 +242,7 @@ PassRefPtr<Event> MouseEvent::cloneFor(HTMLIFrameElement* iframe) const
     ASSERT(iframe);
     RefPtr<MouseEvent> clonedMouseEvent = MouseEvent::create();
     Frame* frame = iframe->document().frame();
     ASSERT(iframe);
     RefPtr<MouseEvent> clonedMouseEvent = MouseEvent::create();
     Frame* frame = iframe->document().frame();
-    FrameView* frameView = frame ? frame->view() : 0;
+    FrameView* frameView = frame ? frame->view() : nullptr;
     clonedMouseEvent->initMouseEvent(type(), bubbles(), cancelable(),
         iframe->document().defaultView(),
         detail(), screenX(), screenY(),
     clonedMouseEvent->initMouseEvent(type(), bubbles(), cancelable(),
         iframe->document().defaultView(),
         detail(), screenX(), screenY(),
index 8322892..8dfdd69 100644 (file)
@@ -93,7 +93,7 @@ public:
     Node* fromElement() const;
 
     // FIXME: These functions can be merged if m_dataTransfer is only initialized for drag events.
     Node* fromElement() const;
 
     // FIXME: These functions can be merged if m_dataTransfer is only initialized for drag events.
-    DataTransfer* dataTransfer() const { return isDragEvent() ? m_dataTransfer.get() : 0; }
+    DataTransfer* dataTransfer() const { return isDragEvent() ? m_dataTransfer.get() : nullptr; }
     virtual DataTransfer* internalDataTransfer() const override { return m_dataTransfer.get(); }
 
     virtual EventInterface eventInterface() const override;
     virtual DataTransfer* internalDataTransfer() const override { return m_dataTransfer.get(); }
 
     virtual EventInterface eventInterface() const override;
index 4dc3704..aa790c2 100644 (file)
@@ -71,7 +71,7 @@ MouseRelatedEvent::MouseRelatedEvent(const AtomicString& eventType, bool canBubb
     LayoutPoint adjustedPageLocation;
     LayoutPoint scrollPosition;
 
     LayoutPoint adjustedPageLocation;
     LayoutPoint scrollPosition;
 
-    Frame* frame = view() ? view()->frame() : 0;
+    Frame* frame = view() ? view()->frame() : nullptr;
     if (frame && !isSimulated) {
         if (FrameView* frameView = frame->view()) {
             scrollPosition = frameView->contentsScrollPosition();
     if (frame && !isSimulated) {
         if (FrameView* frameView = frame->view()) {
             scrollPosition = frameView->contentsScrollPosition();
@@ -150,7 +150,7 @@ void MouseRelatedEvent::receivedTarget()
 
 void MouseRelatedEvent::computeRelativePosition()
 {
 
 void MouseRelatedEvent::computeRelativePosition()
 {
-    Node* targetNode = target() ? target()->toNode() : 0;
+    Node* targetNode = target() ? target()->toNode() : nullptr;
     if (!targetNode)
         return;
 
     if (!targetNode)
         return;
 
index 58f6cb5..ec8f1ee 100644 (file)
@@ -44,7 +44,7 @@ namespace WebCore {
             return adoptRef(*new MutationEvent);
         }
 
             return adoptRef(*new MutationEvent);
         }
 
-        static Ref<MutationEvent> create(const AtomicString& type, bool canBubble, PassRefPtr<Node> relatedNode = 0,
+        static Ref<MutationEvent> create(const AtomicString& type, bool canBubble, PassRefPtr<Node> relatedNode = nullptr,
             const String& prevValue = String(), const String& newValue = String(), const String& attrName = String(), unsigned short attrChange = 0)
         {
             return adoptRef(*new MutationEvent(type, canBubble, false, relatedNode, prevValue, newValue, attrName, attrChange));
             const String& prevValue = String(), const String& newValue = String(), const String& attrName = String(), unsigned short attrChange = 0)
         {
             return adoptRef(*new MutationEvent(type, canBubble, false, relatedNode, prevValue, newValue, attrName, attrChange));
index 1ff1217..387caeb 100644 (file)
@@ -265,10 +265,7 @@ void Node::trackForDebugging()
 Node::Node(Document& document, ConstructionType type)
     : m_refCount(1)
     , m_nodeFlags(type)
 Node::Node(Document& document, ConstructionType type)
     : m_refCount(1)
     , m_nodeFlags(type)
-    , m_parentNode(nullptr)
     , m_treeScope(&document)
     , m_treeScope(&document)
-    , m_previous(nullptr)
-    , m_next(nullptr)
 {
     ASSERT(isMainThread());
 
 {
     ASSERT(isMainThread());
 
@@ -853,7 +850,7 @@ void Node::invalidateNodeListAndCollectionCachesInAncestors(const QualifiedName*
 
 NodeListsNodeData* Node::nodeLists()
 {
 
 NodeListsNodeData* Node::nodeLists()
 {
-    return hasRareData() ? rareData()->nodeLists() : 0;
+    return hasRareData() ? rareData()->nodeLists() : nullptr;
 }
 
 void Node::clearNodeLists()
 }
 
 void Node::clearNodeLists()
@@ -1086,7 +1083,7 @@ Node* Node::nonBoundaryShadowTreeRootNode()
 ContainerNode* Node::nonShadowBoundaryParentNode() const
 {
     ContainerNode* parent = parentNode();
 ContainerNode* Node::nonShadowBoundaryParentNode() const
 {
     ContainerNode* parent = parentNode();
-    return parent && !parent->isShadowRoot() ? parent : 0;
+    return parent && !parent->isShadowRoot() ? parent : nullptr;
 }
 
 Element* Node::parentOrShadowHostElement() const
 }
 
 Element* Node::parentOrShadowHostElement() const
index cb1e7e6..169d40d 100644 (file)
@@ -698,14 +698,13 @@ private:
     int m_refCount;
     mutable uint32_t m_nodeFlags;
 
     int m_refCount;
     mutable uint32_t m_nodeFlags;
 
-    ContainerNode* m_parentNode;
-    TreeScope* m_treeScope;
-    Node* m_previous;
-    Node* m_next;
+    ContainerNode* m_parentNode { nullptr };
+    TreeScope* m_treeScope { nullptr };
+    Node* m_previous { nullptr };
+    Node* m_next { nullptr };
     // When a node has rare data we move the renderer into the rare data.
     union DataUnion {
     // When a node has rare data we move the renderer into the rare data.
     union DataUnion {
-        DataUnion() : m_renderer(0) { }
-        RenderObject* m_renderer;
+        RenderObject* m_renderer { nullptr };
         NodeRareDataBase* m_rareData;
     } m_data;
 
         NodeRareDataBase* m_rareData;
     } m_data;
 
index bd6908c..cb98c33 100644 (file)
@@ -195,7 +195,7 @@ public:
         m_cachedCollections.remove(namedCollectionKey(collection->type(), name));
     }
 
         m_cachedCollections.remove(namedCollectionKey(collection->type(), name));
     }
 
-    void invalidateCaches(const QualifiedName* attrName = 0);
+    void invalidateCaches(const QualifiedName* attrName = nullptr);
     bool isEmpty() const
     {
         return m_atomicNameCaches.isEmpty() && m_cachedCollections.isEmpty() && m_tagCollectionCacheNS.isEmpty();
     bool isEmpty() const
     {
         return m_atomicNameCaches.isEmpty() && m_cachedCollections.isEmpty() && m_tagCollectionCacheNS.isEmpty();
index c602a11..9b70a2a 100644 (file)
@@ -39,7 +39,7 @@ PendingScript::~PendingScript()
 
 PassRefPtr<Element> PendingScript::releaseElementAndClear()
 {
 
 PassRefPtr<Element> PendingScript::releaseElementAndClear()
 {
-    setCachedScript(0);
+    setCachedScript(nullptr);
     m_watchingForLoad = false;
     m_startingPosition = TextPosition::belowRangePosition();
     return m_element.release();
     m_watchingForLoad = false;
     m_startingPosition = TextPosition::belowRangePosition();
     return m_element.release();
index 5742a11..1bd5be8 100644 (file)
@@ -39,16 +39,12 @@ PopStateEventInit::PopStateEventInit()
 
 PopStateEvent::PopStateEvent()
     : Event(eventNames().popstateEvent, false, true)
 
 PopStateEvent::PopStateEvent()
     : Event(eventNames().popstateEvent, false, true)
-    , m_serializedState(0)
-    , m_history(0)
 {
 }
 
 PopStateEvent::PopStateEvent(const AtomicString& type, const PopStateEventInit& initializer)
     : Event(type, initializer)
     , m_state(initializer.state)
 {
 }
 
 PopStateEvent::PopStateEvent(const AtomicString& type, const PopStateEventInit& initializer)
     : Event(type, initializer)
     , m_state(initializer.state)
-    , m_serializedState(0)
-    , m_history(0)
 {
 }
 
 {
 }
 
index 603e88f..0a0ca78 100644 (file)
@@ -128,11 +128,11 @@ public:
     // will be treated as before ignoredNode (thus node() is really after the position, not containing it).
     Node* deprecatedNode() const { return m_anchorNode.get(); }
 
     // will be treated as before ignoredNode (thus node() is really after the position, not containing it).
     Node* deprecatedNode() const { return m_anchorNode.get(); }
 
-    Document* document() const { return m_anchorNode ? &m_anchorNode->document() : 0; }
+    Document* document() const { return m_anchorNode ? &m_anchorNode->document() : nullptr; }
     Element* rootEditableElement() const
     {
         Node* container = containerNode();
     Element* rootEditableElement() const
     {
         Node* container = containerNode();
-        return container ? container->rootEditableElement() : 0;
+        return container ? container->rootEditableElement() : nullptr;
     }
 
     // These should only be used for PositionIsOffsetInAnchor positions, unless
     }
 
     // These should only be used for PositionIsOffsetInAnchor positions, unless
index 4551397..b013521 100644 (file)
@@ -84,7 +84,7 @@ void PositionIterator::decrement()
     if (m_nodeAfterPositionInAnchor) {
         m_anchorNode = m_nodeAfterPositionInAnchor->previousSibling();
         if (m_anchorNode) {
     if (m_nodeAfterPositionInAnchor) {
         m_anchorNode = m_nodeAfterPositionInAnchor->previousSibling();
         if (m_anchorNode) {
-            m_nodeAfterPositionInAnchor = 0;
+            m_nodeAfterPositionInAnchor = nullptr;
             m_offsetInAnchor = m_anchorNode->hasChildNodes() ? 0 : lastOffsetForEditing(m_anchorNode);
         } else {
             m_nodeAfterPositionInAnchor = m_nodeAfterPositionInAnchor->parentNode();
             m_offsetInAnchor = m_anchorNode->hasChildNodes() ? 0 : lastOffsetForEditing(m_anchorNode);
         } else {
             m_nodeAfterPositionInAnchor = m_nodeAfterPositionInAnchor->parentNode();
index 8e0ee19..72cc6ee 100644 (file)
@@ -36,13 +36,6 @@ namespace WebCore {
 // Conversion to/from Position is O(n) in the offset.
 class PositionIterator {
 public:
 // Conversion to/from Position is O(n) in the offset.
 class PositionIterator {
 public:
-    PositionIterator()
-        : m_anchorNode(0)
-        , m_nodeAfterPositionInAnchor(0)
-        , m_offsetInAnchor(0)
-    {
-    }
-
     PositionIterator(const Position& pos)
         : m_anchorNode(pos.anchorNode())
         , m_nodeAfterPositionInAnchor(m_anchorNode->traverseToChildAt(pos.deprecatedEditingOffset()))
     PositionIterator(const Position& pos)
         : m_anchorNode(pos.anchorNode())
         , m_nodeAfterPositionInAnchor(m_anchorNode->traverseToChildAt(pos.deprecatedEditingOffset()))
@@ -64,9 +57,9 @@ public:
     bool isCandidate() const;
 
 private:
     bool isCandidate() const;
 
 private:
-    Node* m_anchorNode;
-    Node* m_nodeAfterPositionInAnchor; // If this is non-null, m_nodeAfterPositionInAnchor->parentNode() == m_anchorNode;
-    int m_offsetInAnchor;
+    Node* m_anchorNode { nullptr };
+    Node* m_nodeAfterPositionInAnchor { nullptr }; // If this is non-null, m_nodeAfterPositionInAnchor->parentNode() == m_anchorNode;
+    int m_offsetInAnchor { 0 };
 };
 
 } // namespace WebCore
 };
 
 } // namespace WebCore
index 9d77e1b..6a6a1c0 100644 (file)
@@ -42,14 +42,6 @@ namespace WebCore {
 inline ProcessingInstruction::ProcessingInstruction(Document& document, const String& target, const String& data)
     : CharacterData(document, data, CreateOther)
     , m_target(target)
 inline ProcessingInstruction::ProcessingInstruction(Document& document, const String& target, const String& data)
     : CharacterData(document, data, CreateOther)
     , m_target(target)
-    , m_cachedSheet(0)
-    , m_loading(false)
-    , m_alternate(false)
-    , m_createdByParser(false)
-    , m_isCSS(false)
-#if ENABLE(XSLT)
-    , m_isXSL(false)
-#endif
 {
 }
 
 {
 }
 
@@ -135,7 +127,7 @@ void ProcessingInstruction::checkStyleSheet()
         } else {
             if (m_cachedSheet) {
                 m_cachedSheet->removeClient(this);
         } else {
             if (m_cachedSheet) {
                 m_cachedSheet->removeClient(this);
-                m_cachedSheet = 0;
+                m_cachedSheet = nullptr;
             }
             
             String url = document().completeURL(href).string();
             }
             
             String url = document().completeURL(href).string();
@@ -232,7 +224,7 @@ void ProcessingInstruction::parseStyleSheet(const String& sheet)
 
     if (m_cachedSheet)
         m_cachedSheet->removeClient(this);
 
     if (m_cachedSheet)
         m_cachedSheet->removeClient(this);
-    m_cachedSheet = 0;
+    m_cachedSheet = nullptr;
 
     m_loading = false;
 
 
     m_loading = false;
 
index efa905b..d429a87 100644 (file)
@@ -80,14 +80,14 @@ private:
     String m_localHref;
     String m_title;
     String m_media;
     String m_localHref;
     String m_title;
     String m_media;
-    CachedResourceHandle<CachedResource> m_cachedSheet;
+    CachedResourceHandle<CachedResource> m_cachedSheet { nullptr };
     RefPtr<StyleSheet> m_sheet;
     RefPtr<StyleSheet> m_sheet;
-    bool m_loading;
-    bool m_alternate;
-    bool m_createdByParser;
-    bool m_isCSS;
+    bool m_loading { false };
+    bool m_alternate { false };
+    bool m_createdByParser { false };
+    bool m_isCSS { false };
 #if ENABLE(XSLT)
 #if ENABLE(XSLT)
-    bool m_isXSL;
+    bool m_isXSL { false };
 #endif
 };
 
 #endif
 };
 
index 5b14a3d..d09915d 100644 (file)
@@ -60,14 +60,12 @@ private:
     static const int invalidOffset = -1;
 
     RefPtr<Node> m_containerNode;
     static const int invalidOffset = -1;
 
     RefPtr<Node> m_containerNode;
-    mutable int m_offsetInContainer;
+    mutable int m_offsetInContainer { 0 };
     RefPtr<Node> m_childBeforeBoundary;
 };
 
 inline RangeBoundaryPoint::RangeBoundaryPoint(PassRefPtr<Node> container)
     : m_containerNode(container)
     RefPtr<Node> m_childBeforeBoundary;
 };
 
 inline RangeBoundaryPoint::RangeBoundaryPoint(PassRefPtr<Node> container)
     : m_containerNode(container)
-    , m_offsetInContainer(0)
-    , m_childBeforeBoundary(0)
 {
     ASSERT(m_containerNode);
 }
 {
     ASSERT(m_containerNode);
 }
index f71f67a..b126c3d 100644 (file)
@@ -57,18 +57,10 @@ namespace WebCore {
 
 ScriptElement::ScriptElement(Element& element, bool parserInserted, bool alreadyStarted)
     : m_element(element)
 
 ScriptElement::ScriptElement(Element& element, bool parserInserted, bool alreadyStarted)
     : m_element(element)
-    , m_cachedScript(0)
     , m_startLineNumber(WTF::OrdinalNumber::beforeFirst())
     , m_parserInserted(parserInserted)
     , m_startLineNumber(WTF::OrdinalNumber::beforeFirst())
     , m_parserInserted(parserInserted)
-    , m_isExternalScript(false)
     , m_alreadyStarted(alreadyStarted)
     , m_alreadyStarted(alreadyStarted)
-    , m_haveFiredLoad(false)
-    , m_willBeParserExecuted(false)
-    , m_readyToBeParserExecuted(false)
-    , m_willExecuteWhenDocumentFinishedParsing(false)
     , m_forceAsync(!parserInserted)
     , m_forceAsync(!parserInserted)
-    , m_willExecuteInOrder(false)
-    , m_requestUsesAccessControl(false)
 {
     if (parserInserted && m_element.document().scriptableDocumentParser() && !m_element.document().isInDocumentWrite())
         m_startLineNumber = m_element.document().scriptableDocumentParser()->textPosition().m_line;
 {
     if (parserInserted && m_element.document().scriptableDocumentParser() && !m_element.document().isInDocumentWrite())
         m_startLineNumber = m_element.document().scriptableDocumentParser()->textPosition().m_line;
@@ -315,7 +307,7 @@ void ScriptElement::stopLoadRequest()
     if (m_cachedScript) {
         if (!m_willBeParserExecuted)
             m_cachedScript->removeClient(this);
     if (m_cachedScript) {
         if (!m_willBeParserExecuted)
             m_cachedScript->removeClient(this);
-        m_cachedScript = 0;
+        m_cachedScript = nullptr;
     }
 }
 
     }
 }
 
@@ -356,7 +348,7 @@ void ScriptElement::notifyFinished(CachedResource* resource)
     else
         m_element.document().scriptRunner()->notifyScriptReady(this, ScriptRunner::ASYNC_EXECUTION);
 
     else
         m_element.document().scriptRunner()->notifyScriptReady(this, ScriptRunner::ASYNC_EXECUTION);
 
-    m_cachedScript = 0;
+    m_cachedScript = nullptr;
 }
 
 bool ScriptElement::ignoresLoadRequest() const
 }
 
 bool ScriptElement::ignoresLoadRequest() const
index b7e73d0..49a7722 100644 (file)
@@ -97,16 +97,16 @@ private:
     Element& m_element;
     CachedResourceHandle<CachedScript> m_cachedScript;
     WTF::OrdinalNumber m_startLineNumber;
     Element& m_element;
     CachedResourceHandle<CachedScript> m_cachedScript;
     WTF::OrdinalNumber m_startLineNumber;
-    bool m_parserInserted : 1;
-    bool m_isExternalScript : 1;
-    bool m_alreadyStarted : 1;
-    bool m_haveFiredLoad : 1;
-    bool m_willBeParserExecuted : 1; // Same as "The parser will handle executing the script."
-    bool m_readyToBeParserExecuted : 1;
-    bool m_willExecuteWhenDocumentFinishedParsing : 1;
-    bool m_forceAsync : 1;
-    bool m_willExecuteInOrder : 1;
-    bool m_requestUsesAccessControl : 1;
+    bool m_parserInserted { false };
+    bool m_isExternalScript { false };
+    bool m_alreadyStarted  { false };
+    bool m_haveFiredLoad  { false };
+    bool m_willBeParserExecuted { false }; // Same as "The parser will handle executing the script."
+    bool m_readyToBeParserExecuted { false };
+    bool m_willExecuteWhenDocumentFinishedParsing { false };
+    bool m_forceAsync { false };
+    bool m_willExecuteInOrder { false };
+    bool m_requestUsesAccessControl { false };
     String m_characterEncoding;
     String m_fallbackCharacterEncoding;
 };
     String m_characterEncoding;
     String m_fallbackCharacterEncoding;
 };
index eaf191b..8e9c9ab 100644 (file)
@@ -57,7 +57,7 @@ public:
         return adoptRef(*new ScriptedAnimationController(document, displayID));
     }
     ~ScriptedAnimationController();
         return adoptRef(*new ScriptedAnimationController(document, displayID));
     }
     ~ScriptedAnimationController();
-    void clearDocumentPointer() { m_document = 0; }
+    void clearDocumentPointer() { m_document = nullptr; }
 
     typedef int CallbackId;
 
 
     typedef int CallbackId;
 
index 5bee5fd..87deb4b 100644 (file)
@@ -46,8 +46,7 @@ COMPILE_ASSERT(sizeof(StyledElement) == sizeof(Element), styledelement_should_re
 using namespace HTMLNames;
 
 struct PresentationAttributeCacheKey {
 using namespace HTMLNames;
 
 struct PresentationAttributeCacheKey {
-    PresentationAttributeCacheKey() : tagName(0) { }
-    AtomicStringImpl* tagName;
+    AtomicStringImpl* tagName { nullptr };
     // Only the values need refcounting.
     Vector<std::pair<AtomicStringImpl*, AtomicString>, 3> attributesAndValues;
 };
     // Only the values need refcounting.
     Vector<std::pair<AtomicStringImpl*, AtomicString>, 3> attributesAndValues;
 };
@@ -267,7 +266,7 @@ void StyledElement::removeAllInlineStyleProperties()
 
 void StyledElement::addSubresourceAttributeURLs(ListHashSet<URL>& urls) const
 {
 
 void StyledElement::addSubresourceAttributeURLs(ListHashSet<URL>& urls) const
 {
-    if (const StyleProperties* inlineStyle = elementData() ? elementData()->inlineStyle() : 0)
+    if (const StyleProperties* inlineStyle = elementData() ? elementData()->inlineStyle() : nullptr)
         inlineStyle->addSubresourceStyleURLs(urls, &document().elementSheet().contents());
 }
 
         inlineStyle->addSubresourceStyleURLs(urls, &document().elementSheet().contents());
 }
 
@@ -341,7 +340,7 @@ void StyledElement::rebuildPresentationAttributeStyle()
     UniqueElementData& elementData = ensureUniqueElementData();
 
     elementData.setPresentationAttributeStyleIsDirty(false);
     UniqueElementData& elementData = ensureUniqueElementData();
 
     elementData.setPresentationAttributeStyleIsDirty(false);
-    elementData.m_presentationAttributeStyle = style->isEmpty() ? 0 : style;
+    elementData.m_presentationAttributeStyle = style->isEmpty() ? nullptr : style;
 
     if (!cacheHash || cacheIterator->value)
         return;
 
     if (!cacheHash || cacheIterator->value)
         return;
index eb2be8b..0e4423c 100644 (file)
@@ -46,7 +46,7 @@ public:
     virtual const StyleProperties* additionalPresentationAttributeStyle() { return 0; }
     void invalidateStyleAttribute();
 
     virtual const StyleProperties* additionalPresentationAttributeStyle() { return 0; }
     void invalidateStyleAttribute();
 
-    const StyleProperties* inlineStyle() const { return elementData() ? elementData()->m_inlineStyle.get() : 0; }
+    const StyleProperties* inlineStyle() const { return elementData() ? elementData()->m_inlineStyle.get() : nullptr; }
     
     bool setInlineStyleProperty(CSSPropertyID, CSSValueID identifier, bool important = false);
     bool setInlineStyleProperty(CSSPropertyID, CSSPropertyID identifier, bool important = false);
     
     bool setInlineStyleProperty(CSSPropertyID, CSSValueID identifier, bool important = false);
     bool setInlineStyleProperty(CSSPropertyID, CSSPropertyID identifier, bool important = false);
index 7bd1d7e..d78b981 100644 (file)
@@ -41,7 +41,7 @@ public:
     }
 
     const Element* host() const { return m_host; }
     }
 
     const Element* host() const { return m_host; }
-    void clearHost() { m_host = 0; }
+    void clearHost() { m_host = nullptr; }
 
 private:
     TemplateContentDocumentFragment(Document& document, const Element* host)
 
 private:
     TemplateContentDocumentFragment(Document& document, const Element* host)
index 69644a5..48b2958 100644 (file)
@@ -74,7 +74,6 @@ TextEvent::TextEvent(PassRefPtr<AbstractView> view, const String& data, TextEven
     : UIEvent(eventNames().textInputEvent, true, true, view, 0)
     , m_inputType(inputType)
     , m_data(data)
     : UIEvent(eventNames().textInputEvent, true, true, view, 0)
     , m_inputType(inputType)
     , m_data(data)
-    , m_pastingFragment(0)
     , m_shouldSmartReplace(false)
     , m_shouldMatchStyle(false)
     , m_mailBlockquoteHandling(MailBlockquoteHandling::RespectBlockquote)
     , m_shouldSmartReplace(false)
     , m_shouldMatchStyle(false)
     , m_mailBlockquoteHandling(MailBlockquoteHandling::RespectBlockquote)
index 4b3dc83..1e9dd6e 100644 (file)
 namespace WebCore {
 
 UIEventInit::UIEventInit()
 namespace WebCore {
 
 UIEventInit::UIEventInit()
-    : view(0)
-    , detail(0)
+    : detail(0)
 {
 }
 
 UIEventInit::UIEventInit(bool bubbles, bool cancelable)
     : EventInit(bubbles, cancelable)
 {
 }
 
 UIEventInit::UIEventInit(bool bubbles, bool cancelable)
     : EventInit(bubbles, cancelable)
-    , view(0)
     , detail(0)
 {
 }
     , detail(0)
 {
 }
index aeaabec..43c61db 100644 (file)
@@ -54,7 +54,7 @@ UserTypingGestureIndicator::UserTypingGestureIndicator(Frame& frame)
     , m_previousFocusedNode(focusedNode())
 {
     s_processingUserTypingGesture = true;
     , m_previousFocusedNode(focusedNode())
 {
     s_processingUserTypingGesture = true;
-    focusedNode() = frame.document() ? frame.document()->focusedElement() : 0;
+    focusedNode() = frame.document() ? frame.document()->focusedElement() : nullptr;
 }
 
 UserTypingGestureIndicator::~UserTypingGestureIndicator()
 }
 
 UserTypingGestureIndicator::~UserTypingGestureIndicator()
index 676cba6..a2b04a7 100644 (file)
@@ -286,7 +286,7 @@ void restrictScaleFactorToInitialScaleIfNotUserScalable(ViewportAttributes& resu
         result.maximumScale = result.minimumScale = result.initialScale;
 }
 
         result.maximumScale = result.minimumScale = result.initialScale;
 }
 
-static float numericPrefix(const String& keyString, const String& valueString, Document* document, bool* ok = 0)
+static float numericPrefix(const String& keyString, const String& valueString, Document* document, bool* ok = nullptr)
 {
     size_t parsedLength;
     float value;
 {
     size_t parsedLength;
     float value;
index b5a682d..50cd59c 100644 (file)
@@ -83,7 +83,7 @@ void MessagePortChannel::disentangle()
 {
     RefPtr<PlatformMessagePortChannel> remote = m_channel->entangledChannel();
     if (remote)
 {
     RefPtr<PlatformMessagePortChannel> remote = m_channel->entangledChannel();
     if (remote)
-        remote->setRemotePort(0);
+        remote->setRemotePort(nullptr);
 }
 
 void MessagePortChannel::postMessageToRemote(PassRefPtr<SerializedScriptValue> message, std::unique_ptr<MessagePortChannelArray> channels)
 }
 
 void MessagePortChannel::postMessageToRemote(PassRefPtr<SerializedScriptValue> message, std::unique_ptr<MessagePortChannelArray> channels)
@@ -154,7 +154,6 @@ Ref<PlatformMessagePortChannel> PlatformMessagePortChannel::create(PassRefPtr<Me
 PlatformMessagePortChannel::PlatformMessagePortChannel(PassRefPtr<MessagePortQueue> incoming, PassRefPtr<MessagePortQueue> outgoing)
     : m_incomingQueue(incoming)
     , m_outgoingQueue(outgoing)
 PlatformMessagePortChannel::PlatformMessagePortChannel(PassRefPtr<MessagePortQueue> incoming, PassRefPtr<MessagePortQueue> outgoing)
     : m_incomingQueue(incoming)
     , m_outgoingQueue(outgoing)
-    , m_remotePort(0)
 {
 }
 
 {
 }
 
index 0306539..4c02261 100644 (file)
@@ -106,7 +106,7 @@ namespace WebCore {
         RefPtr<MessagePortQueue> m_outgoingQueue;
 
         // The port we are connected to (the remote port) - this is the port that is notified when new messages arrive.
         RefPtr<MessagePortQueue> m_outgoingQueue;
 
         // The port we are connected to (the remote port) - this is the port that is notified when new messages arrive.
-        MessagePort* m_remotePort;
+        MessagePort* m_remotePort { nullptr };
     };
 
 } // namespace WebCore
     };
 
 } // namespace WebCore