DCHECK_IS_ON needs ()

Found in the course of reintroducing this bug elsewhere

R=danakj@chromium.org, mark@chromium.org

Review URL: https://codereview.chromium.org/1287043005 .

Patch from Nick Carter <nick@chromium.org>.
This commit is contained in:
Nick Carter 2015-08-12 20:47:36 -04:00 committed by Mark Mentovai
parent eb7ca8c374
commit ad09fd1bc8
4 changed files with 5 additions and 5 deletions

View File

@ -276,7 +276,7 @@ TEST(SimpleStringDictionary, OutOfSpace) {
EXPECT_FALSE(map.GetValueForKey("c"));
}
#if DCHECK_IS_ON
#if DCHECK_IS_ON()
TEST(SimpleStringDictionaryDeathTest, NullKey) {
TSimpleStringDictionary<4, 6, 6> map;

View File

@ -16,7 +16,7 @@
namespace crashpad {
#if DCHECK_IS_ON
#if DCHECK_IS_ON()
InitializationStateDcheck::State InitializationStateDcheck::SetInitializing() {
State old_state = state();

View File

@ -25,7 +25,7 @@
namespace crashpad {
#if DCHECK_IS_ON || DOXYGEN
#if DCHECK_IS_ON() || DOXYGEN
//! \brief Tracks whether data are initialized, triggering a DCHECK assertion
//! on an invalid data access.
@ -168,7 +168,7 @@ struct InitializationStateDcheck {
// technically invalid according to the standard, but clang and g++ accept them
// without complaint even with warnings turned up. They take up no space at all,
// and they can be “initialized” with the same () syntax used to initialize
// objects of the DCHECK_IS_ON InitializationStateDcheck class above.
// objects of the DCHECK_IS_ON() InitializationStateDcheck class above.
using InitializationStateDcheck = bool[0];
#endif // COMPILER_MSVC

View File

@ -29,7 +29,7 @@ TEST(InitializationStateDcheck, InitializationStateDcheck) {
INITIALIZATION_STATE_DCHECK_VALID(initialization_state_dcheck);
}
#if DCHECK_IS_ON
#if DCHECK_IS_ON()
// InitializationStateDcheck only DCHECKs, so the death tests can only run
// when DCHECKs are enabled.