Title: [155422] trunk/Source/WebCore
Revision
155422
Author
[email protected]
Date
2013-09-09 23:16:47 -0700 (Mon, 09 Sep 2013)

Log Message

Adding "explicit" keyword in DOM related classes constructor
https://bugs.webkit.org/show_bug.cgi?id=121031

Patch by Santosh Mahto <[email protected]> on 2013-09-09
Reviewed by Ryosuke Niwa.

Added the explicit keyword in constructors.

* dom/ActiveDOMObject.h:
* dom/ContainerNode.h:
* dom/DocumentStyleSheetCollection.h:
* dom/ElementAncestorIterator.h:
* dom/ElementData.h:
* dom/ElementRareData.h:
* dom/EventListenerMap.h:
* dom/QualifiedName.h:
(WebCore::QualifiedName::QualifiedName):
* dom/TreeScope.h:
* dom/ViewportArguments.h:
(WebCore::ViewportArguments::ViewportArguments):
* dom/VisitedLinkState.h:

Modified Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (155421 => 155422)


--- trunk/Source/WebCore/ChangeLog	2013-09-10 06:10:17 UTC (rev 155421)
+++ trunk/Source/WebCore/ChangeLog	2013-09-10 06:16:47 UTC (rev 155422)
@@ -1,3 +1,26 @@
+2013-09-09  Santosh Mahto  <[email protected]>
+
+        Adding "explicit" keyword in DOM related classes constructor
+        https://bugs.webkit.org/show_bug.cgi?id=121031
+
+        Reviewed by Ryosuke Niwa.
+
+        Added the explicit keyword in constructors.
+
+        * dom/ActiveDOMObject.h:
+        * dom/ContainerNode.h:
+        * dom/DocumentStyleSheetCollection.h:
+        * dom/ElementAncestorIterator.h:
+        * dom/ElementData.h:
+        * dom/ElementRareData.h:
+        * dom/EventListenerMap.h:
+        * dom/QualifiedName.h:
+        (WebCore::QualifiedName::QualifiedName):
+        * dom/TreeScope.h:
+        * dom/ViewportArguments.h:
+        (WebCore::ViewportArguments::ViewportArguments):
+        * dom/VisitedLinkState.h:
+
 2013-09-09  Andreas Kling  <[email protected]>
 
         Remove unreviewed gunk I just accidentally committed :|

Modified: trunk/Source/WebCore/dom/ActiveDOMObject.h (155421 => 155422)


--- trunk/Source/WebCore/dom/ActiveDOMObject.h	2013-09-10 06:10:17 UTC (rev 155421)
+++ trunk/Source/WebCore/dom/ActiveDOMObject.h	2013-09-10 06:16:47 UTC (rev 155422)
@@ -35,7 +35,7 @@
 
 class ActiveDOMObject : public ContextDestructionObserver {
 public:
-    ActiveDOMObject(ScriptExecutionContext*);
+    explicit ActiveDOMObject(ScriptExecutionContext*);
 
     // suspendIfNeeded() should be called exactly once after object construction to synchronize
     // the suspend state with that in ScriptExecutionContext.

Modified: trunk/Source/WebCore/dom/ContainerNode.h (155421 => 155422)


--- trunk/Source/WebCore/dom/ContainerNode.h	2013-09-10 06:10:17 UTC (rev 155421)
+++ trunk/Source/WebCore/dom/ContainerNode.h	2013-09-10 06:16:47 UTC (rev 155422)
@@ -124,7 +124,7 @@
     virtual bool childShouldCreateRenderer(const Node*) const { return true; }
 
 protected:
-    ContainerNode(Document*, ConstructionType = CreateContainer);
+    explicit ContainerNode(Document*, ConstructionType = CreateContainer);
 
     static void queuePostAttachCallback(NodeCallback, Node*, unsigned = 0);
     static bool postAttachCallbacksAreSuspended();

Modified: trunk/Source/WebCore/dom/DocumentStyleSheetCollection.h (155421 => 155422)


--- trunk/Source/WebCore/dom/DocumentStyleSheetCollection.h	2013-09-10 06:10:17 UTC (rev 155421)
+++ trunk/Source/WebCore/dom/DocumentStyleSheetCollection.h	2013-09-10 06:16:47 UTC (rev 155422)
@@ -118,7 +118,7 @@
     bool activeStyleSheetsContains(const CSSStyleSheet*) const;
 
 private:
-    DocumentStyleSheetCollection(Document*);
+    explicit DocumentStyleSheetCollection(Document*);
 
     void collectActiveStyleSheets(Vector<RefPtr<StyleSheet> >&);
     enum StyleResolverUpdateType {

Modified: trunk/Source/WebCore/dom/ElementAncestorIterator.h (155421 => 155422)


--- trunk/Source/WebCore/dom/ElementAncestorIterator.h	2013-09-10 06:10:17 UTC (rev 155421)
+++ trunk/Source/WebCore/dom/ElementAncestorIterator.h	2013-09-10 06:16:47 UTC (rev 155422)
@@ -34,7 +34,7 @@
 class ElementAncestorIterator : public ElementIterator<ElementType> {
 public:
     ElementAncestorIterator();
-    ElementAncestorIterator(ElementType* current);
+    explicit ElementAncestorIterator(ElementType* current);
     ElementAncestorIterator& operator++();
 };
 
@@ -42,14 +42,14 @@
 class ElementAncestorConstIterator : public ElementConstIterator<ElementType> {
 public:
     ElementAncestorConstIterator();
-    ElementAncestorConstIterator(const ElementType* current);
+    explicit ElementAncestorConstIterator(const ElementType* current);
     ElementAncestorConstIterator& operator++();
 };
 
 template <typename ElementType>
 class ElementAncestorIteratorAdapter {
 public:
-    ElementAncestorIteratorAdapter(ElementType* descendant);
+    explicit ElementAncestorIteratorAdapter(ElementType* descendant);
     ElementAncestorIterator<ElementType> begin();
     ElementAncestorIterator<ElementType> end();
 
@@ -60,7 +60,7 @@
 template <typename ElementType>
 class ElementAncestorConstIteratorAdapter {
 public:
-    ElementAncestorConstIteratorAdapter(const ElementType* descendant);
+    explicit ElementAncestorConstIteratorAdapter(const ElementType* descendant);
     ElementAncestorConstIterator<ElementType> begin() const;
     ElementAncestorConstIterator<ElementType> end() const;
 

Modified: trunk/Source/WebCore/dom/ElementData.h (155421 => 155422)


--- trunk/Source/WebCore/dom/ElementData.h	2013-09-10 06:10:17 UTC (rev 155421)
+++ trunk/Source/WebCore/dom/ElementData.h	2013-09-10 06:16:47 UTC (rev 155422)
@@ -75,7 +75,7 @@
 
 protected:
     ElementData();
-    ElementData(unsigned arraySize);
+    explicit ElementData(unsigned arraySize);
     ElementData(const ElementData&, bool isUnique);
 
     unsigned m_isUnique : 1;

Modified: trunk/Source/WebCore/dom/ElementRareData.h (155421 => 155422)


--- trunk/Source/WebCore/dom/ElementRareData.h	2013-09-10 06:10:17 UTC (rev 155421)
+++ trunk/Source/WebCore/dom/ElementRareData.h	2013-09-10 06:16:47 UTC (rev 155422)
@@ -166,7 +166,7 @@
     RefPtr<PseudoElement> m_beforePseudoElement;
     RefPtr<PseudoElement> m_afterPseudoElement;
 
-    ElementRareData(RenderObject*);
+    explicit ElementRareData(RenderObject*);
     void releasePseudoElement(PseudoElement*);
 };
 

Modified: trunk/Source/WebCore/dom/EventListenerMap.h (155421 => 155422)


--- trunk/Source/WebCore/dom/EventListenerMap.h	2013-09-10 06:10:17 UTC (rev 155421)
+++ trunk/Source/WebCore/dom/EventListenerMap.h	2013-09-10 06:16:47 UTC (rev 155422)
@@ -79,7 +79,7 @@
     WTF_MAKE_NONCOPYABLE(EventListenerIterator);
 public:
     EventListenerIterator();
-    EventListenerIterator(EventTarget*);
+    explicit EventListenerIterator(EventTarget*);
 #ifndef NDEBUG
     ~EventListenerIterator();
 #endif

Modified: trunk/Source/WebCore/dom/QualifiedName.h (155421 => 155422)


--- trunk/Source/WebCore/dom/QualifiedName.h	2013-09-10 06:10:17 UTC (rev 155421)
+++ trunk/Source/WebCore/dom/QualifiedName.h	2013-09-10 06:16:47 UTC (rev 155422)
@@ -66,7 +66,7 @@
     };
 
     QualifiedName(const AtomicString& prefix, const AtomicString& localName, const AtomicString& namespaceURI);
-    QualifiedName(WTF::HashTableDeletedValueType) : m_impl(hashTableDeletedValue()) { }
+    explicit QualifiedName(WTF::HashTableDeletedValueType) : m_impl(hashTableDeletedValue()) { }
     bool isHashTableDeletedValue() const { return m_impl == hashTableDeletedValue(); }
     ~QualifiedName();
 #ifdef QNAME_DEFAULT_CONSTRUCTOR

Modified: trunk/Source/WebCore/dom/TreeScope.h (155421 => 155422)


--- trunk/Source/WebCore/dom/TreeScope.h	2013-09-10 06:10:17 UTC (rev 155421)
+++ trunk/Source/WebCore/dom/TreeScope.h	2013-09-10 06:16:47 UTC (rev 155422)
@@ -133,7 +133,7 @@
 
 protected:
     TreeScope(ContainerNode*, Document*);
-    TreeScope(Document*);
+    explicit TreeScope(Document*);
     virtual ~TreeScope();
 
     void destroyTreeScopeData();

Modified: trunk/Source/WebCore/dom/ViewportArguments.h (155421 => 155422)


--- trunk/Source/WebCore/dom/ViewportArguments.h	2013-09-10 06:10:17 UTC (rev 155421)
+++ trunk/Source/WebCore/dom/ViewportArguments.h	2013-09-10 06:16:47 UTC (rev 155422)
@@ -75,7 +75,7 @@
         ValueLandscape = -5
     };
 
-    ViewportArguments(Type type = Implicit)
+    explicit ViewportArguments(Type type = Implicit)
         : type(type)
         , width(ValueAuto)
         , minWidth(ValueAuto)

Modified: trunk/Source/WebCore/dom/VisitedLinkState.h (155421 => 155422)


--- trunk/Source/WebCore/dom/VisitedLinkState.h	2013-09-10 06:10:17 UTC (rev 155421)
+++ trunk/Source/WebCore/dom/VisitedLinkState.h	2013-09-10 06:16:47 UTC (rev 155422)
@@ -50,7 +50,7 @@
     EInsideLink determineLinkState(Element*);
 
 private:
-    VisitedLinkState(Document*);
+    explicit VisitedLinkState(Document*);
 
     EInsideLink determineLinkStateSlowCase(Element*);
 
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to