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

Unified Diff: base/logging.h

Issue 686573003: NOTREACHED should use DCHECK if DCHECK_ALWAYS_ON is set on cros. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 2 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/logging.h
diff --git a/base/logging.h b/base/logging.h
index 54ff57970abe2b5a63507ce77e11f5ae698ef457..f6d2bd649c4145cc30d6771d6e13fee3da4d0921 100644
--- a/base/logging.h
+++ b/base/logging.h
@@ -701,7 +701,7 @@ const LogSeverity LOG_DCHECK = LOG_INFO;
#define DCHECK_GT(val1, val2) DCHECK_OP(GT, > , val1, val2)
#define DCHECK_IMPLIES(val1, val2) DCHECK(!(val1) || (val2))
-#if defined(NDEBUG) && defined(OS_CHROMEOS)
+#if defined(NDEBUG) && !defined(DCHECK_ALWAYS_ON) && defined(OS_CHROMEOS)
Peter Kasting 2014/10/27 21:36:18 This seems fragile. We're slowly redeclaring all
scottmg 2014/10/27 21:38:04 (do while(0) won't work with notreached() << "stuf
dmichael (off chromium) 2014/10/27 21:40:25 do while won't, but it might be OK to use: DCHECK(
danakj 2014/10/27 21:42:34 Why not #if DCHECK_IS_ON?
oshima 2014/10/27 22:04:16 looking at the bug crbug.com/288014, I wonder if w
oshima 2014/10/27 22:04:16 IIRC, DCHECK is no-op on normal rel build.
oshima 2014/10/27 22:04:16 Sure done.
#define NOTREACHED() LOG(ERROR) << "NOTREACHED() hit in " << \
__FUNCTION__ << ". "
#else
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698