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

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

Issue 2698673003: Call HeapObjectHeader::checkHeader solely for its side-effect. (Closed)
Patch Set: Use DCHECK on a bool instead of DCHECK_EQ. Created 3 years, 9 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 | « third_party/WebKit/Source/platform/heap/Member.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/platform/heap/TraceTraits.h
diff --git a/third_party/WebKit/Source/platform/heap/TraceTraits.h b/third_party/WebKit/Source/platform/heap/TraceTraits.h
index d61b64dc5f74fc5aebde7b2528e63d131225e006..de42c5633c37f589ce52f0088b5e1594298b9c0f 100644
--- a/third_party/WebKit/Source/platform/heap/TraceTraits.h
+++ b/third_party/WebKit/Source/platform/heap/TraceTraits.h
@@ -207,7 +207,7 @@ class TraceTrait {
static_assert(!NeedsAdjustAndMark<T>::value,
"wrapper tracing is not supported within mixins");
#if DCHECK_IS_ON()
- DCHECK(HeapObjectHeader::fromPayload(t)->checkHeader());
+ HeapObjectHeader::fromPayload(t)->checkHeader();
#endif
return reinterpret_cast<const T*>(t);
}
@@ -509,7 +509,7 @@ struct TraceInCollectionTrait<NoWeakHandlingInCollections,
T* array = reinterpret_cast<T*>(self);
blink::HeapObjectHeader* header =
blink::HeapObjectHeader::fromPayload(self);
- ASSERT(header->checkHeader());
+ header->checkHeader();
// Use the payload size as recorded by the heap to determine how many
// elements to trace.
size_t length = header->payloadSize() / sizeof(T);
@@ -557,7 +557,7 @@ struct TraceInCollectionTrait<NoWeakHandlingInCollections,
Value* array = reinterpret_cast<Value*>(self);
blink::HeapObjectHeader* header =
blink::HeapObjectHeader::fromPayload(self);
- ASSERT(header->checkHeader());
+ header->checkHeader();
// Use the payload size as recorded by the heap to determine how many
// elements to trace.
size_t length = header->payloadSize() / sizeof(Value);
@@ -611,7 +611,7 @@ struct TraceInCollectionTrait<
Node** array = reinterpret_cast<Node**>(self);
blink::HeapObjectHeader* header =
blink::HeapObjectHeader::fromPayload(self);
- ASSERT(header->checkHeader());
+ header->checkHeader();
size_t length = header->payloadSize() / sizeof(Node*);
for (size_t i = 0; i < length; ++i) {
if (!HashTableHelper<Node*, typename Table::ExtractorType,
« no previous file with comments | « third_party/WebKit/Source/platform/heap/Member.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698