LibreOffice
LibreOffice 6.0 SDK C/C++ API Reference
Macros
diagnose.h File Reference
#include <sal/config.h>
#include <sal/detail/log.h>
#include <sal/saldllapi.h>
#include <sal/types.h>

Go to the source code of this file.

Macros

#define OSL_DEBUG_LEVEL   0
 
#define OSL_LOG_PREFIX   SAL_DETAIL_WHERE
 
#define OSL_TRACE(...)   SAL_DETAIL_INFO_IF_FORMAT(OSL_DEBUG_LEVEL > 0, "legacy.osl", __VA_ARGS__)
 Prints trace message. More...
 
#define OSL_ASSERT(c)   SAL_DETAIL_WARN_IF_FORMAT(!(c), "legacy.osl", "OSL_ASSERT: %s", #c)
 If cond is false, reports an error. More...
 
#define OSL_ENSURE(c, m)   SAL_DETAIL_WARN_IF_FORMAT(!(c), "legacy.osl", "%s", m)
 If cond is false, reports an error with message msg. More...
 
#define OSL_FAIL(m)   SAL_DETAIL_WARN_IF_FORMAT(sal_True, "legacy.osl", "%s", m)
 Reports an error with message msg unconditionally. More...
 
#define OSL_VERIFY(c)   do { if (!(c)) OSL_ASSERT(0); } while (0)
 Evaluates the expression and if it is false, reports an error. More...
 
#define OSL_PRECOND(c, m)    OSL_ENSURE(c, m)
 Check the precondition of functions. More...
 
#define OSL_POSTCOND(c, m)   OSL_ENSURE(c, m)
 Check the postcondition of functions. More...
 
#define OSL_THIS_FUNC   ""
 

Macro Definition Documentation

#define OSL_DEBUG_LEVEL   0
#define OSL_LOG_PREFIX   SAL_DETAIL_WHERE
#define OSL_THIS_FUNC   ""
#define OSL_TRACE (   ...)    SAL_DETAIL_INFO_IF_FORMAT(OSL_DEBUG_LEVEL > 0, "legacy.osl", __VA_ARGS__)

Prints trace message.

The arguments have the same meaning as the arguments of printf.