You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
49 lines
1.6 KiB
49 lines
1.6 KiB
//+--------------------------------------------------------------------------
|
|
//
|
|
// Microsoft Windows
|
|
// Copyright (C) Microsoft Corporation, 1994 - 1996.
|
|
//
|
|
// File: wizdbg.hxx
|
|
//
|
|
// Contents: Debug macros in addition to the ones in ..\folderui\dbg.h
|
|
//
|
|
// History: 4-28-1997 DavidMun Created
|
|
//
|
|
//---------------------------------------------------------------------------
|
|
|
|
|
|
#ifndef __WIZDBG_HXX_
|
|
#define __WIZDBG_HXX_
|
|
|
|
//
|
|
// Technically this isn't a debug macro; but it's frequently used with them
|
|
//
|
|
|
|
#define HRESULT_FROM_LASTERROR HRESULT_FROM_WIN32(GetLastError())
|
|
|
|
//
|
|
// This is defined for debug and retail both. In retail, the DEBUG_OUT
|
|
// section is removed by the precompiler.
|
|
//
|
|
|
|
#define DEBUG_OUT_HRESULT(hr) \
|
|
DEBUG_OUT((DEB_ERROR, \
|
|
"**** ERROR RETURN <%s @line %d> -> %08lx\n", \
|
|
__FILE__, \
|
|
__LINE__, \
|
|
hr))
|
|
|
|
|
|
#define BREAK_ON_FAIL_HRESULT(hr) \
|
|
if (FAILED(hr)) \
|
|
{ \
|
|
DEBUG_OUT_HRESULT(hr); \
|
|
break; \
|
|
}
|
|
|
|
#define TRACE_CONSTRUCTOR(ClassName) TRACE(ClassName, ClassName)
|
|
#define TRACE_DESTRUCTOR(ClassName) TRACE(ClassName, ~##ClassName)
|
|
#define TRACE_METHOD TRACE
|
|
|
|
#endif // __WIZDBG_HXX_
|
|
|