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

Unified Diff: Source/platform/heap/ThreadState.h

Issue 646833003: Oilpan: Mark the NodeList hierarchy MainThreadOnly (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 2 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 | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/platform/heap/ThreadState.h
diff --git a/Source/platform/heap/ThreadState.h b/Source/platform/heap/ThreadState.h
index 0eb1cb409f052fed3a00ef21cc41170831ab1960..b6405a8fee1d13baf529a6e6061a7341ef851050 100644
--- a/Source/platform/heap/ThreadState.h
+++ b/Source/platform/heap/ThreadState.h
@@ -84,10 +84,15 @@ enum ThreadAffinity {
MainThreadOnly,
};
+// FIXME: These forward declarations violate dependency rules. Remove them.
+// Ideally we want to provide a USED_IN_MAIN_THREAD_ONLY(T) macro, which
+// indicates that classes in T's hierarchy are used only by the main thread.
class Node;
-class CSSValue;
+class NodeList;
-template<typename T, bool derivesNode = WTF::IsSubclass<typename WTF::RemoveConst<T>::Type, Node>::value> struct DefaultThreadingTrait;
+template<typename T,
+ bool mainThreadOnly = WTF::IsSubclass<typename WTF::RemoveConst<T>::Type, Node>::value
+ || WTF::IsSubclass<typename WTF::RemoveConst<T>::Type, NodeList>::value> struct DefaultThreadingTrait;
template<typename T>
struct DefaultThreadingTrait<T, false> {
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698