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

Unified Diff: base/sequence_checker.h

Issue 2163023002: Unify usage of logging/assert macros in base/ (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix base/android/build_info.cc compile 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
« no previous file with comments | « base/numerics/safe_numerics_unittest.cc ('k') | base/task/cancelable_task_tracker_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/sequence_checker.h
diff --git a/base/sequence_checker.h b/base/sequence_checker.h
index bb7b346acf36d3049f34c3269d45c66b972fcdd2..471631844ba7da9a8ceb8a908767b1795eed0721 100644
--- a/base/sequence_checker.h
+++ b/base/sequence_checker.h
@@ -5,13 +5,6 @@
#ifndef BASE_SEQUENCE_CHECKER_H_
#define BASE_SEQUENCE_CHECKER_H_
-// See comments for the similar block in thread_checker.h.
-#if (!defined(NDEBUG) || defined(DCHECK_ALWAYS_ON))
-#define ENABLE_SEQUENCE_CHECKER 1
-#else
-#define ENABLE_SEQUENCE_CHECKER 0
-#endif
-
#include "base/sequence_checker_impl.h"
namespace base {
@@ -46,15 +39,13 @@ class SequenceCheckerDoNothing {
// }
//
// In Release mode, CalledOnValidSequence() will always return true.
-#if ENABLE_SEQUENCE_CHECKER
+#if DCHECK_IS_ON()
class SequenceChecker : public SequenceCheckerImpl {
};
#else
class SequenceChecker : public SequenceCheckerDoNothing {
};
-#endif // ENABLE_SEQUENCE_CHECKER
-
-#undef ENABLE_SEQUENCE_CHECKER
+#endif // DCHECK_IS_ON()
} // namespace base
« no previous file with comments | « base/numerics/safe_numerics_unittest.cc ('k') | base/task/cancelable_task_tracker_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698