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

Side by Side Diff: Source/platform/heap/ThreadState.h

Issue 282263006: Oilpan: remove consts when checking GC-class convertibility. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: 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 unified diff | Download patch
« no previous file with comments | « Source/platform/heap/Handle.h ('k') | Source/platform/heap/Visitor.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2013 Google Inc. All rights reserved. 2 * Copyright (C) 2013 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after
74 // rid of it if it is fast enough to go through thread-local storage 74 // rid of it if it is fast enough to go through thread-local storage
75 // always. 75 // always.
76 enum ThreadAffinity { 76 enum ThreadAffinity {
77 AnyThread, 77 AnyThread,
78 MainThreadOnly, 78 MainThreadOnly,
79 }; 79 };
80 80
81 class Node; 81 class Node;
82 class CSSValue; 82 class CSSValue;
83 83
84 template<typename T, bool derivesNode = WTF::IsSubclass<T, Node>::value> struct DefaultThreadingTrait; 84 template<typename T, bool derivesNode = WTF::IsSubclass<typename WTF::RemoveCons t<T>::Type, Node>::value> struct DefaultThreadingTrait;
85 85
86 template<typename T> 86 template<typename T>
87 struct DefaultThreadingTrait<T, false> { 87 struct DefaultThreadingTrait<T, false> {
88 static const ThreadAffinity Affinity = AnyThread; 88 static const ThreadAffinity Affinity = AnyThread;
89 }; 89 };
90 90
91 template<typename T> 91 template<typename T>
92 struct DefaultThreadingTrait<T, true> { 92 struct DefaultThreadingTrait<T, true> {
93 static const ThreadAffinity Affinity = MainThreadOnly; 93 static const ThreadAffinity Affinity = MainThreadOnly;
94 }; 94 };
(...skipping 501 matching lines...) Expand 10 before | Expand all | Expand 10 after
596 }; 596 };
597 597
598 template<> class ThreadStateFor<AnyThread> { 598 template<> class ThreadStateFor<AnyThread> {
599 public: 599 public:
600 static ThreadState* state() { return ThreadState::current(); } 600 static ThreadState* state() { return ThreadState::current(); }
601 }; 601 };
602 602
603 } 603 }
604 604
605 #endif // ThreadState_h 605 #endif // ThreadState_h
OLDNEW
« no previous file with comments | « Source/platform/heap/Handle.h ('k') | Source/platform/heap/Visitor.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698