Logo Search packages:      
Sourcecode: virtualbox-ose version File versions

assert.h File Reference


Detailed Description

innotek Portable Runtime - Assertions.

Definition in file assert.h.

#include <iprt/cdefs.h>
#include <iprt/types.h>

Go to the source code of this file.

Defines

#define Assert(expr)   do { } while (0)
#define AssertBreak(expr, stmt)
#define AssertBreakpoint()   do { } while (0)
#define AssertCompile(expr)   typedef int RTASSERTTYPE[(expr) ? 1 : 0]
#define AssertCompileMemberAlignment(type, member, align)   AssertCompile(!(RT_OFFSETOF(type, member) & ((align) - 1)))
#define AssertCompileMemberSize(type, member, size)   AssertCompile(RT_SIZEOFMEMB(type, member) == (size))
#define AssertCompileMemberSizeAlignment(type, member, align)   AssertCompile(!(RT_SIZEOFMEMB(type, member) & ((align) - 1)))
#define AssertCompileSize(type, size)   AssertCompile(sizeof(type) == (size))
#define AssertCompileSizeAlignment(type, align)   AssertCompile(!(sizeof(type) & ((align) - 1)))
#define AssertFailed()   do { } while (0)
#define AssertFailedBreak(stmt)
#define AssertFailedReturn(rc)
#define AssertFailedReturnVoid()
#define AssertFatal(expr)
#define AssertFatalFailed()
#define AssertFatalMsg(expr, a)
#define AssertFatalMsgFailed(a)
#define AssertFatalMsgRC(rc, msg)   AssertFatalMsg(RT_SUCCESS(rc), msg)
#define AssertFatalRC(rc)   AssertFatalMsgRC(rc, ("%Vra\n", (rc)))
#define AssertFatalRCSuccess(rc)   AssertFatalMsg((rc) == VINF_SUCCESS, ("%Vra\n", (rc)))
#define AssertMsg(expr, a)   do { } while (0)
#define AssertMsgBreak(expr, a, stmt)
#define AssertMsgFailed(a)   do { } while (0)
#define AssertMsgFailedBreak(a, stmt)
#define AssertMsgFailedReturn(a, rc)
#define AssertMsgFailedReturnVoid(a)
#define AssertMsgRC(rc, msg)   do { AssertMsg(RT_SUCCESS(rc), msg); NOREF(rc); } while (0)
#define AssertMsgRCBreak(rc, msg, stmt)   do { AssertMsgBreak(RT_SUCCESS(rc), msg, stmt); NOREF(rc); } while (0)
#define AssertMsgRCReturn(rc, msg, rcRet)   do { AssertMsgReturn(RT_SUCCESS(rc), msg, rcRet); NOREF(rc); } while (0)
#define AssertMsgRCReturnVoid(rc, msg)   do { AssertMsgReturnVoid(RT_SUCCESS(rc), msg); NOREF(rc); } while (0)
#define AssertMsgReturn(expr, a, rc)
#define AssertMsgReturnVoid(expr, a)
#define AssertPtr(pv)   AssertMsg(VALID_PTR(pv), ("%p\n", (pv)))
#define AssertPtrBreak(pv, stmt)   AssertMsgBreak(VALID_PTR(pv), ("%p\n", (pv)), stmt)
#define AssertPtrNull(pv)   AssertMsg(VALID_PTR(pv) || (pv) == NULL, ("%p\n", (pv)))
#define AssertPtrNullBreak(pv, stmt)   AssertMsgBreak(VALID_PTR(pv) || (pv) == NULL, ("%p\n", (pv)), stmt)
#define AssertPtrNullReturn(pv, rcRet)   AssertMsgReturn(VALID_PTR(pv) || (pv) == NULL, ("%p\n", (pv)), rcRet)
#define AssertPtrNullReturnVoid(pv)   AssertMsgReturnVoid(VALID_PTR(pv) || (pv) == NULL, ("%p\n", (pv)))
#define AssertPtrReturn(pv, rcRet)   AssertMsgReturn(VALID_PTR(pv), ("%p\n", (pv)), rcRet)
#define AssertPtrReturnVoid(pv)   AssertMsgReturnVoid(VALID_PTR(pv), ("%p\n", (pv)))
#define AssertRC(rc)   AssertMsgRC(rc, ("%Vra\n", (rc)))
#define AssertRCBreak(rc, stmt)   AssertMsgRCBreak(rc, ("%Vra\n", (rc)), stmt)
#define AssertRCReturn(rc, rcRet)   AssertMsgRCReturn(rc, ("%Vra\n", (rc)), rcRet)
#define AssertRCReturnVoid(rc)   AssertMsgRCReturnVoid(rc, ("%Vra\n", (rc)))
#define AssertRCSuccess(rc)   AssertMsg((rc) == VINF_SUCCESS, ("%Vra\n", (rc)))
#define AssertRCSuccessBreak(rc, stmt)   AssertMsgBreak((rc) == VINF_SUCCESS, ("%Vra\n", (rc)), stmt)
#define AssertRCSuccessReturn(rc, rcRet)   AssertMsgReturn((rc) == VINF_SUCCESS, ("%Vra\n", (rc)), rcRet)
#define AssertRCSuccessReturnVoid(rc)   AssertMsgReturnVoid((rc) == VINF_SUCCESS, ("%Vra\n", (rc)))
#define AssertRelease(expr)
#define AssertReleaseBreak(expr, stmt)
#define AssertReleaseFailed()
#define AssertReleaseFailedBreak(stmt)
#define AssertReleaseFailedReturn(rc)
#define AssertReleaseFailedReturnVoid()
#define AssertReleaseMsg(expr, a)
#define AssertReleaseMsgBreak(expr, a, stmt)
#define AssertReleaseMsgFailed(a)
#define AssertReleaseMsgFailedBreak(a, stmt)
#define AssertReleaseMsgFailedReturn(a, rc)
#define AssertReleaseMsgFailedReturnVoid(a)
#define AssertReleaseMsgRC(rc, msg)   AssertReleaseMsg(RT_SUCCESS(rc), msg)
#define AssertReleaseMsgRCBreak(rc, msg, stmt)   AssertReleaseMsgBreak(RT_SUCCESS(rc), msg, stmt)
#define AssertReleaseMsgRCReturn(rc, msg, rcRet)   AssertReleaseMsgReturn(RT_SUCCESS(rc), msg, rcRet)
#define AssertReleaseMsgRCReturnVoid(rc, msg)   AssertReleaseMsgReturnVoid(RT_SUCCESS(rc), msg)
#define AssertReleaseMsgReturn(expr, a, rc)
#define AssertReleaseMsgReturnVoid(expr, a)
#define AssertReleaseRC(rc)   AssertReleaseMsgRC(rc, ("%Vra\n", (rc)))
#define AssertReleaseRCBreak(rc, stmt)   AssertReleaseMsgRCBreak(rc, ("%Vra\n", (rc)), stmt)
#define AssertReleaseRCReturn(rc, rcRet)   AssertReleaseMsgRCReturn(rc, ("%Vra\n", (rc)), rcRet)
#define AssertReleaseRCReturnVoid(rc)   AssertReleaseMsgRCReturnVoid(rc, ("%Vra\n", (rc)))
#define AssertReleaseRCSuccess(rc)   AssertReleaseMsg((rc) == VINF_SUCCESS, ("%Vra\n", (rc)))
#define AssertReleaseRCSuccessBreak(rc, stmt)   AssertReleaseMsgBreak((rc) == VINF_SUCCESS, ("%Vra\n", (rc)), stmt)
#define AssertReleaseRCSuccessReturn(rc, rcRet)   AssertReleaseMsgReturn((rc) == VINF_SUCCESS, ("%Vra\n", (rc)), rcRet)
#define AssertReleaseRCSuccessReturnVoid(rc)   AssertReleaseMsgReturnVoid((rc) == VINF_SUCCESS, ("%Vra\n", (rc)))
#define AssertReleaseReturn(expr, rc)
#define AssertReleaseReturnVoid(expr)
#define AssertReturn(expr, rc)
#define AssertReturnVoid(expr)

Typedefs

typedef int RTASSERTTYPE [1]

Functions

 RTDATADECL (char) g_szRTAssertMsg1[1024]
 RTDECL (bool) RTAssertDoBreakpoint(void)
Release Logging
__BEGIN_DECLS RTDECL (void) AssertMsg1(const char *pszExpr

Variables

int RTASSERTVAR [1]
__BEGIN_DECLS unsigned uLine
R3 DevHlp
__BEGIN_DECLS unsigned const char * pszFile
__BEGIN_DECLS unsigned const
char const char * 
pszFunction


Generated by  Doxygen 1.6.0   Back to index