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

Unified Diff: third_party/WebKit/Source/web/WebDevToolsAgentImpl.cpp

Issue 1839643009: RELEASE_ASSERT -> CHECK and ASSERT -> DCHECK in web. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Return DCHECK_IS_ON checks. Created 4 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
Index: third_party/WebKit/Source/web/WebDevToolsAgentImpl.cpp
diff --git a/third_party/WebKit/Source/web/WebDevToolsAgentImpl.cpp b/third_party/WebKit/Source/web/WebDevToolsAgentImpl.cpp
index 4fe39138964c566766b68777281dad9e03ffdc28..1f1287a052ae75afd34457135b59622d541075db 100644
--- a/third_party/WebKit/Source/web/WebDevToolsAgentImpl.cpp
+++ b/third_party/WebKit/Source/web/WebDevToolsAgentImpl.cpp
@@ -301,7 +301,7 @@ WebDevToolsAgentImpl::WebDevToolsAgentImpl(
: m_client(client)
, m_webLocalFrameImpl(webLocalFrameImpl)
, m_attached(false)
-#if ENABLE(ASSERT)
+#if DCHECK_IS_ON()
, m_hasBeenDisposed(false)
#endif
, m_instrumentingAgents(m_webLocalFrameImpl->frame()->instrumentingAgents())
@@ -319,13 +319,15 @@ WebDevToolsAgentImpl::WebDevToolsAgentImpl(
, m_stateMuted(false)
, m_layerTreeId(0)
{
- ASSERT(isMainThread());
- ASSERT(m_webLocalFrameImpl->frame());
+ DCHECK(isMainThread());
+ DCHECK(m_webLocalFrameImpl->frame());
}
WebDevToolsAgentImpl::~WebDevToolsAgentImpl()
{
- ASSERT(m_hasBeenDisposed);
+#if DCHECK_IS_ON()
+ DCHECK(m_hasBeenDisposed);
+#endif
}
void WebDevToolsAgentImpl::dispose()
@@ -334,8 +336,8 @@ void WebDevToolsAgentImpl::dispose()
// same behavior (and correctness) with and without Oilpan.
if (m_attached)
Platform::current()->currentThread()->removeTaskObserver(this);
-#if ENABLE(ASSERT)
- ASSERT(!m_hasBeenDisposed);
+#if DCHECK_IS_ON()
+ DCHECK(!m_hasBeenDisposed);
m_hasBeenDisposed = true;
#endif
}
@@ -369,8 +371,8 @@ DEFINE_TRACE(WebDevToolsAgentImpl)
void WebDevToolsAgentImpl::willBeDestroyed()
{
- ASSERT(m_webLocalFrameImpl->frame());
- ASSERT(m_inspectedFrames->root()->view());
+ DCHECK(m_webLocalFrameImpl->frame());
+ DCHECK(m_inspectedFrames->root()->view());
detach();
m_resourceContentLoader->dispose();
« no previous file with comments | « third_party/WebKit/Source/web/WebDevToolsAgentImpl.h ('k') | third_party/WebKit/Source/web/WebDevToolsFrontendImpl.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698