Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(422)

Unified Diff: Source/core/dom/DOMImplementation.h

Issue 271673005: Oilpan: move DOMImplementation to the heap. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Adjust signature Created 6 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | Source/core/dom/DOMImplementation.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/dom/DOMImplementation.h
diff --git a/Source/core/dom/DOMImplementation.h b/Source/core/dom/DOMImplementation.h
index f954c8fd6b9bd489843f83d1a1267b22bec7310a..326f072e29b85f1d6020cd8b163b1028f2b244e9 100644
--- a/Source/core/dom/DOMImplementation.h
+++ b/Source/core/dom/DOMImplementation.h
@@ -40,14 +40,19 @@ class HTMLDocument;
class KURL;
class XMLDocument;
-class DOMImplementation : public ScriptWrappable {
- WTF_MAKE_FAST_ALLOCATED;
+class DOMImplementation FINAL : public NoBaseWillBeGarbageCollectedFinalized<DOMImplementation>, public ScriptWrappable {
+ WTF_MAKE_FAST_ALLOCATED_WILL_BE_REMOVED;
public:
- static PassOwnPtr<DOMImplementation> create(Document& document) { return adoptPtr(new DOMImplementation(document)); }
+ static PassOwnPtrWillBeRawPtr<DOMImplementation> create(Document& document)
+ {
+ return adoptPtrWillBeNoop(new DOMImplementation(document));
+ }
- void ref() { m_document.ref(); }
- void deref() { m_document.deref(); }
- Document& document() const { return m_document; }
+#if !ENABLE(OILPAN)
+ void ref() { m_document->ref(); }
+ void deref() { m_document->deref(); }
+#endif
+ Document& document() const { return *m_document.get(); }
Mads Ager (chromium) 2014/05/08 07:31:11 You can remove the .get() call here. Both RawPtr<T
// DOM methods & attributes for DOMImplementation
static bool hasFeature(const String& feature, const String& version);
@@ -66,10 +71,12 @@ public:
static bool isTextMIMEType(const String&);
static bool isJSONMIMEType(const String&);
+ void trace(Visitor*);
+
private:
explicit DOMImplementation(Document&);
- Document& m_document;
+ RawPtrWillBeMember<Document> m_document;
};
} // namespace WebCore
« no previous file with comments | « no previous file | Source/core/dom/DOMImplementation.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698