Remove workaround for compilers not supporting deleted functions

https://bugs.webkit.org/show_bug.cgi?id=127166

Patch by Peter Molnar <pmolnar.u-szeged@partner.samsung.com> on 2014-01-17
Reviewed by Andreas Kling.

Source/JavaScriptCore:

* inspector/InspectorAgentRegistry.h:

Source/WebCore:

* bindings/js/JSLazyEventListener.h:
* dom/ContainerNode.h:
* dom/Document.h:
* dom/Element.h:
* rendering/InlineFlowBox.h:
* rendering/InlineTextBox.h:
* rendering/RenderButton.h:
* rendering/RenderCombineText.h:
* rendering/RenderElement.h:
* rendering/RenderFieldset.h:
* rendering/RenderFileUploadControl.h:
* rendering/RenderFrame.h:
* rendering/RenderFrameBase.h:
* rendering/RenderFrameSet.h:
* rendering/RenderHTMLCanvas.h:
* rendering/RenderIFrame.h:
* rendering/RenderLineBreak.h:
* rendering/RenderListBox.h:
* rendering/RenderListMarker.h:
* rendering/RenderMedia.h:
* rendering/RenderMenuList.h:
* rendering/RenderSnapshottedPlugIn.h:
* rendering/RenderTableCell.h:
* rendering/RenderTableRow.h:
* rendering/RenderTableSection.h:
* rendering/RenderText.h:
* rendering/RenderTextControl.h:
* rendering/RenderTextControlMultiLine.h:
* rendering/RenderTextControlSingleLine.h:
* rendering/RenderVideo.h:
* rendering/RenderWidget.h:
* rendering/svg/RenderSVGBlock.h:
* rendering/svg/RenderSVGForeignObject.h:
* rendering/svg/RenderSVGImage.h:
* rendering/svg/RenderSVGInline.h:
* rendering/svg/RenderSVGRect.h:
* rendering/svg/RenderSVGResourceClipper.h:
* rendering/svg/RenderSVGResourceFilter.h:
* rendering/svg/RenderSVGResourceFilterPrimitive.h:
* rendering/svg/RenderSVGResourceGradient.h:
* rendering/svg/RenderSVGResourceLinearGradient.h:
* rendering/svg/RenderSVGResourceMarker.h:
* rendering/svg/RenderSVGResourceMasker.h:
* rendering/svg/RenderSVGResourcePattern.h:
* rendering/svg/RenderSVGResourceRadialGradient.h:
* rendering/svg/RenderSVGRoot.h:
* rendering/svg/RenderSVGShape.h:
* rendering/svg/RenderSVGTSpan.h:
* rendering/svg/RenderSVGText.h:
* rendering/svg/RenderSVGTextPath.h:
* rendering/svg/RenderSVGTransformableContainer.h:
* rendering/svg/RenderSVGViewportContainer.h:
* xml/XPathValue.h:

Source/WTF:

* wtf/Compiler.h:
* wtf/Noncopyable.h:
* wtf/PassRefPtr.h:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@162198 268f45cc-cd09-0410-ab3c-d52691b4dbfc
parent f4216bb8
2014-01-17 Peter Molnar <pmolnar.u-szeged@partner.samsung.com>
Remove workaround for compilers not supporting deleted functions
https://bugs.webkit.org/show_bug.cgi?id=127166
Reviewed by Andreas Kling.
* inspector/InspectorAgentRegistry.h:
2014-01-17 Commit Queue <commit-queue@webkit.org>
Unreviewed, rolling out r162185, r162186, and r162187.
......
......@@ -48,8 +48,8 @@ public:
private:
// These are declared here to avoid MSVC from trying to create default iplementations which would
// involve generating a copy constructor and copy assignment operator for the Vector of std::unique_ptrs.
InspectorAgentRegistry(const InspectorAgentRegistry&) WTF_DELETED_FUNCTION;
InspectorAgentRegistry& operator=(const InspectorAgentRegistry&) WTF_DELETED_FUNCTION;
InspectorAgentRegistry(const InspectorAgentRegistry&) = delete;
InspectorAgentRegistry& operator=(const InspectorAgentRegistry&) = delete;
Vector<std::unique_ptr<InspectorAgentBase>> m_agents;
};
......
2014-01-17 Peter Molnar <pmolnar.u-szeged@partner.samsung.com>
Remove workaround for compilers not supporting deleted functions
https://bugs.webkit.org/show_bug.cgi?id=127166
Reviewed by Andreas Kling.
* wtf/Compiler.h:
* wtf/Noncopyable.h:
* wtf/PassRefPtr.h:
2014-01-16 Benjamin Poulain <bpoulain@apple.com>
Remove Nix from WTF
......
......@@ -253,11 +253,6 @@
#define WARN_UNUSED_RETURN
#endif
#if COMPILER_SUPPORTS(CXX_DELETED_FUNCTIONS)
#define WTF_DELETED_FUNCTION = delete
#else
#define WTF_DELETED_FUNCTION
#endif
/* REFERENCED_FROM_ASM */
......
......@@ -25,7 +25,7 @@
#define WTF_MAKE_NONCOPYABLE(ClassName) \
private: \
ClassName(const ClassName&) WTF_DELETED_FUNCTION; \
ClassName& operator=(const ClassName&) WTF_DELETED_FUNCTION; \
ClassName(const ClassName&) = delete; \
ClassName& operator=(const ClassName&) = delete; \
#endif // WTF_Noncopyable_h
......@@ -70,7 +70,7 @@ namespace WTF {
friend PassRefPtr adoptRef<T>(T*);
private:
PassRefPtr& operator=(const PassRefPtr&) WTF_DELETED_FUNCTION;
PassRefPtr& operator=(const PassRefPtr&) = delete;
enum AdoptTag { Adopt };
PassRefPtr(T* ptr, AdoptTag) : m_ptr(ptr) { }
......
2014-01-17 Peter Molnar <pmolnar.u-szeged@partner.samsung.com>
Remove workaround for compilers not supporting deleted functions
https://bugs.webkit.org/show_bug.cgi?id=127166
Reviewed by Andreas Kling.
* bindings/js/JSLazyEventListener.h:
* dom/ContainerNode.h:
* dom/Document.h:
* dom/Element.h:
* rendering/InlineFlowBox.h:
* rendering/InlineTextBox.h:
* rendering/RenderButton.h:
* rendering/RenderCombineText.h:
* rendering/RenderElement.h:
* rendering/RenderFieldset.h:
* rendering/RenderFileUploadControl.h:
* rendering/RenderFrame.h:
* rendering/RenderFrameBase.h:
* rendering/RenderFrameSet.h:
* rendering/RenderHTMLCanvas.h:
* rendering/RenderIFrame.h:
* rendering/RenderLineBreak.h:
* rendering/RenderListBox.h:
* rendering/RenderListMarker.h:
* rendering/RenderMedia.h:
* rendering/RenderMenuList.h:
* rendering/RenderSnapshottedPlugIn.h:
* rendering/RenderTableCell.h:
* rendering/RenderTableRow.h:
* rendering/RenderTableSection.h:
* rendering/RenderText.h:
* rendering/RenderTextControl.h:
* rendering/RenderTextControlMultiLine.h:
* rendering/RenderTextControlSingleLine.h:
* rendering/RenderVideo.h:
* rendering/RenderWidget.h:
* rendering/svg/RenderSVGBlock.h:
* rendering/svg/RenderSVGForeignObject.h:
* rendering/svg/RenderSVGImage.h:
* rendering/svg/RenderSVGInline.h:
* rendering/svg/RenderSVGRect.h:
* rendering/svg/RenderSVGResourceClipper.h:
* rendering/svg/RenderSVGResourceFilter.h:
* rendering/svg/RenderSVGResourceFilterPrimitive.h:
* rendering/svg/RenderSVGResourceGradient.h:
* rendering/svg/RenderSVGResourceLinearGradient.h:
* rendering/svg/RenderSVGResourceMarker.h:
* rendering/svg/RenderSVGResourceMasker.h:
* rendering/svg/RenderSVGResourcePattern.h:
* rendering/svg/RenderSVGResourceRadialGradient.h:
* rendering/svg/RenderSVGRoot.h:
* rendering/svg/RenderSVGShape.h:
* rendering/svg/RenderSVGTSpan.h:
* rendering/svg/RenderSVGText.h:
* rendering/svg/RenderSVGTextPath.h:
* rendering/svg/RenderSVGTransformableContainer.h:
* rendering/svg/RenderSVGViewportContainer.h:
* xml/XPathValue.h:
2014-01-17 Zan Dobersek <zdobersek@igalia.com>
[ATK] Modernize the for loops in ATK AX code
......@@ -43,7 +43,7 @@ namespace WebCore {
virtual JSC::JSObject* initializeJSFunction(ScriptExecutionContext*) const override;
virtual bool wasCreatedFromMarkup() const override { return true; }
static void create() WTF_DELETED_FUNCTION;
static void create() = delete;
mutable String m_functionName;
mutable String m_eventParameterName;
......
......@@ -169,7 +169,7 @@ private:
void updateTreeAfterInsertion(Node& child);
bool isContainerNode() const WTF_DELETED_FUNCTION;
bool isContainerNode() const = delete;
Node* m_firstChild;
Node* m_lastChild;
......
......@@ -1235,8 +1235,8 @@ private:
void commonTeardown();
RenderObject* renderer() const WTF_DELETED_FUNCTION;
void setRenderer(RenderObject*) WTF_DELETED_FUNCTION;
RenderObject* renderer() const = delete;
void setRenderer(RenderObject*) = delete;
void createRenderTree();
void detachParser();
......
......@@ -674,7 +674,7 @@ private:
bool isJavaScriptURLAttribute(const Attribute&) const;
// Anyone thinking of using this should call document instead of ownerDocument.
void ownerDocument() const WTF_DELETED_FUNCTION;
void ownerDocument() const = delete;
QualifiedName m_tagName;
RefPtr<ElementData> m_elementData;
......
......@@ -296,7 +296,7 @@ public:
private:
virtual bool isInlineFlowBox() const override final { return true; }
void boxModelObject() const WTF_DELETED_FUNCTION;
void boxModelObject() const = delete;
void addBoxShadowVisualOverflow(LayoutRect& logicalVisualOverflow);
void addBorderOutsetVisualOverflow(LayoutRect& logicalVisualOverflow);
......
......@@ -182,7 +182,7 @@ private:
| (expansion() && nextLeafChild() ? TextRun::AllowTrailingExpansion : TextRun::ForbidTrailingExpansion);
}
void behavesLikeText() const WTF_DELETED_FUNCTION;
void behavesLikeText() const = delete;
InlineTextBox* m_prevTextBox; // The previous box that also uses our RenderObject
InlineTextBox* m_nextTextBox; // The next box that also uses our RenderObject
......
......@@ -62,7 +62,7 @@ public:
#endif
private:
void element() const WTF_DELETED_FUNCTION;
void element() const = delete;
virtual const char* renderName() const override { return "RenderButton"; }
virtual bool isRenderButton() const override { return true; }
......
......@@ -43,7 +43,7 @@ public:
const Font& textCombineFont() const { return m_combineFontStyle->font(); }
private:
void node() const WTF_DELETED_FUNCTION;
void node() const = delete;
virtual bool isCombineText() const { return true; }
virtual float width(unsigned from, unsigned length, const Font&, float xPosition, HashSet<const SimpleFontData*>* fallbackFonts = 0, GlyphOverflow* = 0) const;
......
......@@ -177,11 +177,11 @@ protected:
bool renderInlineAlwaysCreatesLineBoxes() const { return m_renderInlineAlwaysCreatesLineBoxes; }
private:
void node() const WTF_DELETED_FUNCTION;
void nonPseudoNode() const WTF_DELETED_FUNCTION;
void generatingNode() const WTF_DELETED_FUNCTION;
void isText() const WTF_DELETED_FUNCTION;
void isRenderElement() const WTF_DELETED_FUNCTION;
void node() const = delete;
void nonPseudoNode() const = delete;
void generatingNode() const = delete;
void isText() const = delete;
void isRenderElement() const = delete;
virtual RenderObject* firstChildSlow() const override final { return firstChild(); }
virtual RenderObject* lastChildSlow() const override final { return lastChild(); }
......
......@@ -41,7 +41,7 @@ public:
HTMLFieldSetElement& fieldSetElement() const { return toHTMLFieldSetElement(nodeForNonAnonymous()); }
private:
void element() const WTF_DELETED_FUNCTION;
void element() const = delete;
virtual const char* renderName() const override { return "RenderFieldSet"; }
virtual bool isFieldset() const override { return true; }
......
......@@ -42,7 +42,7 @@ public:
HTMLInputElement& inputElement() const;
private:
void element() const WTF_DELETED_FUNCTION;
void element() const = delete;
virtual bool isFileUploadControl() const override { return true; }
......
......@@ -38,7 +38,7 @@ public:
FrameEdgeInfo edgeInfo() const;
private:
void frameOwnerElement() const WTF_DELETED_FUNCTION;
void frameOwnerElement() const = delete;
virtual const char* renderName() const override { return "RenderFrame"; }
virtual bool isFrame() const override { return true; }
......
......@@ -44,7 +44,7 @@ public:
void layoutWithFlattening(bool fixedWidth, bool fixedHeight);
private:
void widget() const WTF_DELETED_FUNCTION;
void widget() const = delete;
};
} // namespace WebCore
......
......@@ -73,7 +73,7 @@ public:
void notifyFrameEdgeInfoChanged();
private:
void element() const WTF_DELETED_FUNCTION;
void element() const = delete;
static const int noSplit = -1;
......
......@@ -41,7 +41,7 @@ public:
void canvasSizeChanged();
private:
void element() const WTF_DELETED_FUNCTION;
void element() const = delete;
virtual bool requiresLayer() const override;
virtual bool isCanvas() const override { return true; }
virtual const char* renderName() const override { return "RenderHTMLCanvas"; }
......
......@@ -42,7 +42,7 @@ public:
bool isSeamless() const;
private:
void frameOwnerElement() const WTF_DELETED_FUNCTION;
void frameOwnerElement() const = delete;
virtual LayoutUnit minPreferredLogicalWidth() const override;
virtual LayoutUnit maxPreferredLogicalWidth() const override;
......
......@@ -53,7 +53,7 @@ public:
virtual void absoluteQuads(Vector<FloatQuad>&, bool* wasFixed) const override;
private:
void node() const WTF_DELETED_FUNCTION;
void node() const = delete;
virtual bool canHaveChildren() const override { return false; }
virtual void paint(PaintInfo&, const LayoutPoint&) override final { }
......
......@@ -60,7 +60,7 @@ public:
int size() const;
private:
void element() const WTF_DELETED_FUNCTION;
void element() const = delete;
virtual const char* renderName() const override { return "RenderListBox"; }
......
......@@ -46,7 +46,7 @@ public:
void updateMarginsAndContent();
private:
void element() const WTF_DELETED_FUNCTION;
void element() const = delete;
virtual const char* renderName() const override { return "RenderListMarker"; }
virtual void computePreferredLogicalWidths() override;
......
......@@ -45,7 +45,7 @@ protected:
virtual void layout();
private:
void element() const WTF_DELETED_FUNCTION;
void element() const = delete;
virtual bool canHaveChildren() const override final { return true; }
......
......@@ -61,7 +61,7 @@ public:
String text() const;
private:
void element() const WTF_DELETED_FUNCTION;
void element() const = delete;
virtual bool isMenuList() const override { return true; }
......
......@@ -46,7 +46,7 @@ public:
void handleEvent(Event*);
private:
void frameOwnerElement() const WTF_DELETED_FUNCTION;
void frameOwnerElement() const = delete;
virtual const char* renderName() const { return "RenderSnapshottedPlugIn"; }
virtual CursorDirective getCursor(const LayoutPoint&, Cursor&) const override final;
......
......@@ -284,8 +284,8 @@ private:
unsigned parseRowSpanFromDOM() const;
unsigned parseColSpanFromDOM() const;
void nextSibling() const WTF_DELETED_FUNCTION;
void previousSibling() const WTF_DELETED_FUNCTION;
void nextSibling() const = delete;
void previousSibling() const = delete;
// Note MSVC will only pack members if they have identical types, hence we use unsigned instead of bool here.
unsigned m_column : 29;
......
......@@ -111,10 +111,10 @@ private:
virtual void styleDidChange(StyleDifference, const RenderStyle* oldStyle) override;
void firstChild() const WTF_DELETED_FUNCTION;
void lastChild() const WTF_DELETED_FUNCTION;
void nextSibling() const WTF_DELETED_FUNCTION;
void previousSibling() const WTF_DELETED_FUNCTION;
void firstChild() const = delete;
void lastChild() const = delete;
void nextSibling() const = delete;
void previousSibling() const = delete;
unsigned m_rowIndex : 31;
};
......
......@@ -279,8 +279,8 @@ private:
void setLogicalPositionForCell(RenderTableCell*, unsigned effectiveColumn) const;
void firstChild() const WTF_DELETED_FUNCTION;
void lastChild() const WTF_DELETED_FUNCTION;
void firstChild() const = delete;
void lastChild() const = delete;
Vector<RowStruct> m_grid;
Vector<int> m_rowPos;
......
......@@ -185,7 +185,7 @@ private:
void secureText(UChar mask);
void node() const WTF_DELETED_FUNCTION;
void node() const = delete;
// We put the bitfield first to minimize padding on 64-bit.
bool m_hasBreakableChar : 1; // Whether or not we can be broken into multiple lines.
......
......@@ -72,7 +72,7 @@ protected:
virtual RenderObject* layoutSpecialExcludedChild(bool relayoutChildren) override;
private:
void element() const WTF_DELETED_FUNCTION;
void element() const = delete;
virtual const char* renderName() const override { return "RenderTextControl"; }
virtual bool isTextControl() const override final { return true; }
......
......@@ -36,7 +36,7 @@ public:
HTMLTextAreaElement& textAreaElement() const;
private:
void element() const WTF_DELETED_FUNCTION;
void element() const = delete;
virtual bool isTextArea() const { return true; }
......
......@@ -48,7 +48,7 @@ protected:
HTMLInputElement& inputElement() const;
private:
void textFormControlElement() const WTF_DELETED_FUNCTION;
void textFormControlElement() const = delete;
virtual bool hasControlClip() const override;
virtual LayoutRect controlClipRect(const LayoutPoint&) const override;
......
......@@ -55,7 +55,7 @@ public:
virtual bool shouldDisplayVideo() const;
private:
void mediaElement() const WTF_DELETED_FUNCTION;
void mediaElement() const = delete;
virtual void updateFromElement();
......
......@@ -89,7 +89,7 @@ protected:
#endif
private:
void element() const WTF_DELETED_FUNCTION;
void element() const = delete;
virtual bool isWidget() const override final { return true; }
......
......@@ -40,7 +40,7 @@ protected:
virtual void willBeDestroyed() override;
private:
void element() const WTF_DELETED_FUNCTION;
void element() const = delete;
virtual void updateFromStyle() override final;
......
......@@ -59,7 +59,7 @@ public:
virtual void setNeedsTransformUpdate() { m_needsTransformUpdate = true; }
private:
void graphicsElement() const WTF_DELETED_FUNCTION;
void graphicsElement() const = delete;
virtual const char* renderName() const override { return "RenderSVGForeignObject"; }
virtual void updateLogicalWidth() override;
......
......@@ -54,7 +54,7 @@ public:
void paintForeground(PaintInfo&);
private:
void element() const WTF_DELETED_FUNCTION;
void element() const = delete;
virtual const char* renderName() const { return "RenderSVGImage"; }
virtual bool isSVGImage() const override { return true; }
......
......@@ -34,7 +34,7 @@ public:
SVGGraphicsElement& graphicsElement() const { return toSVGGraphicsElement(nodeForNonAnonymous()); }
private:
void element() const WTF_DELETED_FUNCTION;
void element() const = delete;
virtual const char* renderName() const override { return "RenderSVGInline"; }
virtual bool requiresLayer() const override final { return false; }
......
......@@ -42,7 +42,7 @@ public:
SVGRectElement& rectElement() const;
private:
void graphicsElement() const WTF_DELETED_FUNCTION;
void graphicsElement() const = delete;
virtual const char* renderName() const { return "RenderSVGRect"; }
......
......@@ -63,7 +63,7 @@ public:
static RenderSVGResourceType s_resourceType;
private:
void element() const WTF_DELETED_FUNCTION;
void element() const = delete;
virtual const char* renderName() const override { return "RenderSVGResourceClipper"; }
......
......@@ -88,7 +88,7 @@ public:
FloatRect drawingRegion(RenderObject*) const;
private:
void element() const WTF_DELETED_FUNCTION;
void element() const = delete;
virtual const char* renderName() const override { return "RenderSVGResourceFilter"; }
virtual bool isSVGResourceFilter() const override { return true; }
......
......@@ -57,7 +57,7 @@ public:
static_cast<RenderSVGResourceFilter*>(filter)->primitiveAttributeChanged(this, attribute);
}
private:
void element() const WTF_DELETED_FUNCTION;
void element() const = delete;
};
} // namespace WebCore
......
......@@ -55,7 +55,7 @@ public:
protected:
RenderSVGResourceGradient(SVGGradientElement&, PassRef<RenderStyle>);
void element() const WTF_DELETED_FUNCTION;
void element() const = delete;
void addStops(GradientData*, const Vector<Gradient::ColorStop>&) const;
......
......@@ -47,7 +47,7 @@ public:
FloatPoint endPoint(const LinearGradientAttributes&) const;
private:
void gradientElement() const WTF_DELETED_FUNCTION;
void gradientElement() const = delete;
virtual const char* renderName() const override { return "RenderSVGResourceLinearGradient"; }
......
......@@ -64,7 +64,7 @@ public:
static RenderSVGResourceType s_resourceType;
private:
void element() const WTF_DELETED_FUNCTION;
void element() const = delete;
virtual const char* renderName() const override { return "RenderSVGResourceMarker"; }
......
......@@ -55,7 +55,7 @@ public:
static RenderSVGResourceType s_resourceType;
private:
void element() const WTF_DELETED_FUNCTION;
void element() const = delete;
virtual const char* renderName() const override { return "RenderSVGResourceMasker"; }
......
......@@ -56,7 +56,7 @@ public:
static RenderSVGResourceType s_resourceType;
private:
void element() const WTF_DELETED_FUNCTION;
void element() const = delete;
virtual const char* renderName() const override { return "RenderSVGResourcePattern"; }
bool buildTileImageTransform(RenderObject*, const PatternAttributes&, const SVGPatternElement&, FloatRect& patternBoundaries, AffineTransform& tileImageTransform) const;
......
......@@ -50,7 +50,7 @@ public:
float focalRadius(const RadialGradientAttributes&) const;
private:
void gradientElement() const WTF_DELETED_FUNCTION;
void gradientElement() const = delete;
virtual const char* renderName() const override { return "RenderSVGResourceRadialGradient"; }
virtual bool collectGradientAttributes() override;
......
......@@ -69,7 +69,7 @@ public:
void setHasSVGShadow(bool hasShadow) { m_hasSVGShadow = hasShadow; }
private:
void element() const WTF_DELETED_FUNCTION;
void element() const = delete;
virtual bool isSVGRoot() const override { return true; }
virtual const char* renderName() const override { return "RenderSVGRoot"; }
......
......@@ -67,7 +67,7 @@ public:
}
protected:
void element() const WTF_DELETED_FUNCTION;
void element() const = delete;
virtual void updateShapeFromElement();
virtual bool isEmpty() const override;
......
......@@ -37,7 +37,7 @@ public:
SVGTextPositioningElement& textPositioningElement() const { return static_cast<SVGTextPositioningElement&>(RenderSVGInline::graphicsElement()); }
private:
void graphicsElement() const WTF_DELETED_FUNCTION;
void graphicsElement() const = delete;
virtual const char* renderName() const { return "RenderSVGTSpan"; }
};
}
......
......@@ -60,7 +60,7 @@ public:
void subtreeTextDidChange(RenderSVGInlineText*);
private:
void graphicsElement() const WTF_DELETED_FUNCTION;
void graphicsElement() const = delete;
virtual const char* renderName() const { return "RenderSVGText"; }
virtual bool isSVGText() const { return true; }
......
......@@ -38,7 +38,7 @@ public:
bool stretchMethod() const;
private:
void graphicsElement() const WTF_DELETED_FUNCTION;
void graphicsElement() const = delete;
virtual bool isSVGTextPath() const override { return true; }
virtual const char* renderName() const override { return "RenderSVGTextPath"; }
......