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

Unified Diff: third_party/WebKit/Source/platform/heap/HeapAllocator.h

Issue 1477213003: More switching to standard type traits (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Excluded WTF::IsSubclass from the patch Created 5 years 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/platform/heap/HeapAllocator.h
diff --git a/third_party/WebKit/Source/platform/heap/HeapAllocator.h b/third_party/WebKit/Source/platform/heap/HeapAllocator.h
index 259c46b52d0b72c5e96d5927e3886f6452ec9b3e..ea42c891e7969af168895193838850052a23d199 100644
--- a/third_party/WebKit/Source/platform/heap/HeapAllocator.h
+++ b/third_party/WebKit/Source/platform/heap/HeapAllocator.h
@@ -250,7 +250,7 @@ void HeapVectorBacking<T, Traits>::finalize(void* pointer)
{
static_assert(Traits::needsDestruction, "Only vector buffers with items requiring destruction should be finalized");
// See the comment in HeapVectorBacking::trace.
- static_assert(Traits::canClearUnusedSlotsWithMemset || WTF::IsPolymorphic<T>::value, "HeapVectorBacking doesn't support objects that cannot be cleared as unused with memset or don't have a vtable");
+ static_assert(Traits::canClearUnusedSlotsWithMemset || std::is_polymorphic<T>::value, "HeapVectorBacking doesn't support objects that cannot be cleared as unused with memset or don't have a vtable");
ASSERT(!WTF::IsTriviallyDestructible<T>::value);
HeapObjectHeader* header = HeapObjectHeader::fromPayload(pointer);
@@ -264,7 +264,7 @@ void HeapVectorBacking<T, Traits>::finalize(void* pointer)
// (which are already zeroed out).
ANNOTATE_CHANGE_SIZE(buffer, length, 0, length);
#endif
- if (WTF::IsPolymorphic<T>::value) {
+ if (std::is_polymorphic<T>::value) {
for (unsigned i = 0; i < length; ++i) {
if (blink::vTableInitialized(&buffer[i]))
buffer[i].~T();
« no previous file with comments | « third_party/WebKit/Source/platform/heap/GCInfo.h ('k') | third_party/WebKit/Source/platform/heap/TraceTraits.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698