Chromium Code Reviews| Index: third_party/WebKit/Source/wtf/Assertions.h |
| diff --git a/third_party/WebKit/Source/wtf/Assertions.h b/third_party/WebKit/Source/wtf/Assertions.h |
| index 3962562ffd6f36121f90cd2ff3a97a00b36e33f2..ef5268cd40bfd907c98727a319984849627ba543 100644 |
| --- a/third_party/WebKit/Source/wtf/Assertions.h |
| +++ b/third_party/WebKit/Source/wtf/Assertions.h |
| @@ -51,12 +51,13 @@ |
| // Users must test "#if ENABLE(ASSERT)", which helps ensure that code |
| // testing this macro has included this header. |
| #ifndef ENABLE_ASSERT |
| -#if defined(NDEBUG) && !defined(DCHECK_ALWAYS_ON) |
| +#if DCHECK_IS_ON() && !defined(DCHECK_IS_DUMP_WITHOUT_CRASH) |
| +/* Enable ASSERT* macros if DCHECK is on, unless it dumps-without-crashing. */ |
|
Nico
2016/03/31 22:11:17
nit: use // comments
also, don't repeat the line a
|
| +#define ENABLE_ASSERT 1 |
| +#else |
| /* Disable ASSERT* macros in release mode by default. */ |
| #define ENABLE_ASSERT 0 |
| -#else |
| -#define ENABLE_ASSERT 1 |
| -#endif /* defined(NDEBUG) && !defined(DCHECK_ALWAYS_ON) */ |
| +#endif /* DCHECK_IS_ON() */ |
| #endif |
| #ifndef ASSERT_MSG_DISABLED |