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

Unified Diff: base/synchronization/cancellation_flag.h

Issue 2163023002: Unify usage of logging/assert macros in base/ (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 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
Index: base/synchronization/cancellation_flag.h
diff --git a/base/synchronization/cancellation_flag.h b/base/synchronization/cancellation_flag.h
index f2f83f47dadd651542ad3f65f8101b77a86fc8eb..91961dbb01b27bd37c4e803f4d6184c3de8184a9 100644
--- a/base/synchronization/cancellation_flag.h
+++ b/base/synchronization/cancellation_flag.h
@@ -7,6 +7,7 @@
#include "base/atomicops.h"
#include "base/base_export.h"
+#include "base/logging.h"
#include "base/macros.h"
#include "base/threading/platform_thread.h"
@@ -20,7 +21,7 @@ namespace base {
class BASE_EXPORT CancellationFlag {
public:
CancellationFlag() : flag_(false) {
-#if !defined(NDEBUG)
+#if DCHECK_IS_ON()
set_on_ = PlatformThread::CurrentId();
#endif
}
@@ -37,7 +38,7 @@ class BASE_EXPORT CancellationFlag {
private:
base::subtle::Atomic32 flag_;
-#if !defined(NDEBUG)
+#if DCHECK_IS_ON()
PlatformThreadId set_on_;
#endif

Powered by Google App Engine
This is Rietveld 408576698