Assert that a condition is true in debug builds only.

Synopsis

Declared in <folly/logging/xlog.h>

#define XDCHECK(cond, …​)

Description

When NDEBUG is not defined this behaves like XCHECK(). When NDEBUG is defined XDCHECK statements are not evaluated and will never log.

You can use XLOG_IF(DFATAL, condition) instead if you want the condition to be evaluated in release builds but log a message without crashing the program.

Parameters

Name

Description

cond

The condition expression that must evaluate to true.

Created with MrDocs