Home | History | Annotate | Download | only in base

Lines Matching full:condition

58 // The CHECK(condition) macro is active in both debug and release builds and
103 // There's also VLOG_IS_ON(n) "verbose level" condition macro. To be used as
110 // There is also a VLOG_IF "verbose level" condition macro for sample
126 // PCHECK(condition) << "Couldn't do foo";
127 // DPCHECK(condition) << "Couldn't do foo";
246 // values, and there is a race condition that may leak a critical section
387 // the condition doesn't hold. Condition is evaluated once and only once.
388 #define LAZY_STREAM(stream, condition) \
389 !(condition) ? (void) 0 : ::logging::LogMessageVoidify() & (stream)
402 #define LOG_IF(severity, condition) \
403 LAZY_STREAM(LOG_STREAM(severity), LOG_IS_ON(severity) && (condition))
406 #define SYSLOG_IF(severity, condition) LOG_IF(severity, condition)
415 #define VLOG_IF(verbose_level, condition) \
417 VLOG_IS_ON(verbose_level) && (condition))
432 #define VPLOG_IF(verbose_level, condition) \
434 VLOG_IS_ON(verbose_level) && (condition))
438 #define LOG_ASSERT(condition) \
439 LOG_IF(FATAL, !(condition)) << "Assert failed: " #condition ". "
440 #define SYSLOG_ASSERT(condition) \
441 SYSLOG_IF(FATAL, !(condition)) << "Assert failed: " #condition ". "
456 #define PLOG_IF(severity, condition) \
457 LAZY_STREAM(PLOG_STREAM(severity), LOG_IS_ON(severity) && (condition))
478 // CHECK dies with a fatal error if condition is not true. It is *not*
493 #define CHECK(condition) \
494 !(condition) ? ::base::debug::BreakDebugger() : EAT_STREAM_PARAMETERS
496 #define PCHECK(condition) CHECK(condition)
505 // parameter doesn't reference 'condition' in /analyze builds because
506 // this evaluation confuses /analyze. The !! before condition is because
510 #define CHECK(condition) \
511 __analysis_assume(!!(condition)), \
513 << "Check failed: " #condition ". "
515 #define PCHECK(condition) \
516 __analysis_assume(!!(condition)), \
518 << "Check failed: " #condition ". "
523 #define CHECK(condition) \
524 LAZY_STREAM(logging::LogMessage(__FILE__, __LINE__, #condition).stream(), \
525 !(condition))
527 #define PCHECK(condition) \
528 LAZY_STREAM(PLOG_STREAM(FATAL), !(condition)) \
529 << "Check failed: " #condition ". "
626 #define DLOG_IF(severity, condition) LOG_IF(severity, condition)
627 #define DLOG_ASSERT(condition) LOG_ASSERT(condition)
628 #define DPLOG_IF(severity, condition) PLOG_IF(severity, condition)
629 #define DVLOG_IF(verboselevel, condition) VLOG_IF(verboselevel, condition)
630 #define DVPLOG_IF(verboselevel, condition) VPLOG_IF(verboselevel, condition)
635 // |condition| (which may reference a variable defined only if NDEBUG
640 #define DLOG_IF(severity, condition) EAT_STREAM_PARAMETERS
641 #define DLOG_ASSERT(condition) EAT_STREAM_PARAMETERS
642 #define DPLOG_IF(severity, condition) EAT_STREAM_PARAMETERS
643 #define DVLOG_IF(verboselevel, condition) EAT_STREAM_PARAMETERS
644 #define DVPLOG_IF(verboselevel, condition) EAT_STREAM_PARAMETERS
689 // DCHECK et al. make sure to reference |condition| regardless of
697 #define DCHECK(condition) \
698 __analysis_assume(!!(condition)), \
700 << "Check failed: " #condition ". "
702 #define DPCHECK(condition) \
703 __analysis_assume(!!(condition)), \
705 << "Check failed: " #condition ". "
709 #define DCHECK(condition) \
710 LAZY_STREAM(LOG_STREAM(DCHECK), DCHECK_IS_ON() ? !(condition) : false) \
711 << "Check failed: " #condition ". "
713 #define DPCHECK(condition) \
714 LAZY_STREAM(PLOG_STREAM(DCHECK), DCHECK_IS_ON() ? !(condition) : false) \
715 << "Check failed: " #condition ". "
791 LogMessage(const char* file, int line, const char* condition);
920 #define RAW_CHECK(condition) \
922 if (!(condition)) \
923 logging::RawLog(logging::LOG_FATAL, "Check failed: " #condition "\n"); \