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

Unified Diff: Source/wtf/ThreadRestrictionVerifier.h

Issue 397733004: Allow assertions to be enabled in Blink Release builds. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Rebased. Created 6 years, 5 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 | « Source/wtf/TerminatedArrayBuilder.h ('k') | Source/wtf/WTF.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/wtf/ThreadRestrictionVerifier.h
diff --git a/Source/wtf/ThreadRestrictionVerifier.h b/Source/wtf/ThreadRestrictionVerifier.h
index b6ba662be9107572cfce510c3dfdbf079da07227..ba08137d165ef6a4d541c3274fc98065d7811aa3 100644
--- a/Source/wtf/ThreadRestrictionVerifier.h
+++ b/Source/wtf/ThreadRestrictionVerifier.h
@@ -31,9 +31,10 @@
#ifndef ThreadRestrictionVerifier_h
#define ThreadRestrictionVerifier_h
-#ifndef NDEBUG
-
#include "wtf/Assertions.h"
+
+#if ENABLE(ASSERT)
+
#include "wtf/Threading.h"
namespace WTF {
@@ -53,9 +54,7 @@ public:
// Indicates that the object may (or may not) be owned by more than one place.
void setShared(bool shared)
{
-#if ENABLE(ASSERT)
bool previouslyShared = m_shared;
-#endif
m_shared = shared;
if (!m_shared)
@@ -84,5 +83,5 @@ private:
}
-#endif // !NDEBUG
+#endif // ENABLE(ASSERT)
#endif // ThreadRestrictionVerifier_h
« no previous file with comments | « Source/wtf/TerminatedArrayBuilder.h ('k') | Source/wtf/WTF.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698