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

Unified Diff: third_party/WebKit/Source/core/dom/Document.cpp

Issue 1850413002: Improve DEFINE_STATIC_LOCAL()'s handling of Blink GCed objects. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: address compilation failure Created 4 years, 8 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
Index: third_party/WebKit/Source/core/dom/Document.cpp
diff --git a/third_party/WebKit/Source/core/dom/Document.cpp b/third_party/WebKit/Source/core/dom/Document.cpp
index dd206adbfa48fd9f62820dcf5d678c72ec804dd6..dae347c7eed3cb2beeaa3708f6564629b8a72db9 100644
--- a/third_party/WebKit/Source/core/dom/Document.cpp
+++ b/third_party/WebKit/Source/core/dom/Document.cpp
@@ -363,8 +363,8 @@ static bool s_threadedParsingEnabledForTesting = true;
Document::WeakDocumentSet& Document::liveDocumentSet()
{
- DEFINE_STATIC_LOCAL(Persistent<WeakDocumentSet>, set, (new WeakDocumentSet()));
- return *set;
+ DEFINE_STATIC_LOCAL(WeakDocumentSet, set, (new WeakDocumentSet));
+ return set;
}
// This class doesn't work with non-Document ExecutionContext.
« no previous file with comments | « third_party/WebKit/Source/core/dom/ContextFeatures.cpp ('k') | third_party/WebKit/Source/core/dom/DocumentOrderedMap.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698