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

Unified Diff: third_party/WebKit/Source/core/events/EventListenerMap.h

Issue 2270293002: Replace ASSERT*() with DCHECK*() in core/events/. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: isUnreachableNode -> checkReachableNode Created 4 years, 4 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/events/EventListenerMap.h
diff --git a/third_party/WebKit/Source/core/events/EventListenerMap.h b/third_party/WebKit/Source/core/events/EventListenerMap.h
index 43b1348cd3e48ad600352c2e2aa644d73694b6f9..85ebebba0262c6d50f3fed18c47ad21eacdb83f9 100644
--- a/third_party/WebKit/Source/core/events/EventListenerMap.h
+++ b/third_party/WebKit/Source/core/events/EventListenerMap.h
@@ -67,7 +67,7 @@ public:
private:
friend class EventListenerIterator;
- void assertNoActiveIterators();
+ void checkNoActiveIterators();
// We use HeapVector instead of HeapHashMap because
// - HeapVector is much more space efficient than HeapHashMap.
@@ -75,8 +75,8 @@ private:
// HeapVector is faster in such cases.
HeapVector<std::pair<AtomicString, Member<EventListenerVector>>, 2> m_entries;
-#if ENABLE(ASSERT)
- int m_activeIteratorCount;
+#if DCHECK_IS_ON()
+ int m_activeIteratorCount = 0;
#endif
};
@@ -85,7 +85,7 @@ class EventListenerIterator {
STACK_ALLOCATED();
public:
explicit EventListenerIterator(EventTarget*);
-#if ENABLE(ASSERT)
+#if DCHECK_IS_ON()
~EventListenerIterator();
#endif
@@ -99,8 +99,8 @@ private:
unsigned m_index;
};
-#if !ENABLE(ASSERT)
-inline void EventListenerMap::assertNoActiveIterators() { }
+#if !DCHECK_IS_ON()
+inline void EventListenerMap::checkNoActiveIterators() { }
#endif
} // namespace blink
« no previous file with comments | « third_party/WebKit/Source/core/events/EventDispatcher.cpp ('k') | third_party/WebKit/Source/core/events/EventListenerMap.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698