diff options
Diffstat (limited to 'base/threading/thread_checker.h')
-rw-r--r-- | base/threading/thread_checker.h | 12 |
1 files changed, 4 insertions, 8 deletions
diff --git a/base/threading/thread_checker.h b/base/threading/thread_checker.h index 449247af9d..1d970f093e 100644 --- a/base/threading/thread_checker.h +++ b/base/threading/thread_checker.h @@ -5,23 +5,19 @@ #ifndef BASE_THREADING_THREAD_CHECKER_H_ #define BASE_THREADING_THREAD_CHECKER_H_ +#include "base/logging.h" +#include "base/threading/thread_checker_impl.h" + // Apart from debug builds, we also enable the thread checker in // builds with DCHECK_ALWAYS_ON so that trybots and waterfall bots // with this define will get the same level of thread checking as // debug bots. -// -// Note that this does not perfectly match situations where DCHECK is -// enabled. For example a non-official release build may have -// DCHECK_ALWAYS_ON undefined (and therefore ThreadChecker would be -// disabled) but have DCHECKs enabled at runtime. -#if (!defined(NDEBUG) || defined(DCHECK_ALWAYS_ON)) +#if DCHECK_IS_ON() #define ENABLE_THREAD_CHECKER 1 #else #define ENABLE_THREAD_CHECKER 0 #endif -#include "base/threading/thread_checker_impl.h" - namespace base { // Do nothing implementation, for use in release mode. |