From 2f0b265e8de775007ac7fa4979db8f0121230527 Mon Sep 17 00:00:00 2001 From: Serge Gautherie <32623169+SergeGautherie@users.noreply.github.com> Date: Thu, 6 Jun 2019 01:50:24 +0200 Subject: [PATCH] [DXSDK] Improve dxerr?.h a bit (#1617) *Use '||', instead of '|', on a '#if'. *Synchronize some white spaces and blank lines. --- sdk/include/dxsdk/dxerr8.h | 6 +----- sdk/include/dxsdk/dxerr9.h | 9 +++------ 2 files changed, 4 insertions(+), 11 deletions(-) diff --git a/sdk/include/dxsdk/dxerr8.h b/sdk/include/dxsdk/dxerr8.h index aeaea5a62f7..79947f9424f 100644 --- a/sdk/include/dxsdk/dxerr8.h +++ b/sdk/include/dxsdk/dxerr8.h @@ -1,5 +1,4 @@ - #ifndef _DXERR8_H_ #define _DXERR8_H_ @@ -15,7 +14,6 @@ const WCHAR* WINAPI DXGetErrorString8W(HRESULT hr); const WCHAR* WINAPI DXGetErrorDescription8W(HRESULT hr); HRESULT WINAPI DXTraceW( const char* strFile, DWORD dwLine, HRESULT hr, const WCHAR* strMsg, BOOL bPopMsgBox ); - #ifdef UNICODE #define DXGetErrorString8 DXGetErrorString8W #define DXGetErrorDescription8 DXGetErrorDescription8W @@ -26,7 +24,7 @@ HRESULT WINAPI DXTraceW( const char* strFile, DWORD dwLine, HRESULT hr, const WC #define DXTrace DXTraceA #endif -#if defined(DEBUG) | defined(_DEBUG) +#if defined(DEBUG) || defined(_DEBUG) #define DXTRACE_MSG(str) DXTrace( __FILE__, (DWORD)__LINE__, 0, str, FALSE ) #define DXTRACE_ERR(str,hr) DXTrace( __FILE__, (DWORD)__LINE__, hr, str, TRUE ) #define DXTRACE_ERR_NOMSGBOX(str,hr) DXTrace( __FILE__, (DWORD)__LINE__, hr, str, FALSE ) @@ -36,10 +34,8 @@ HRESULT WINAPI DXTraceW( const char* strFile, DWORD dwLine, HRESULT hr, const WC #define DXTRACE_ERR_NOMSGBOX(str,hr) (hr) #endif - #ifdef __cplusplus } #endif #endif - diff --git a/sdk/include/dxsdk/dxerr9.h b/sdk/include/dxsdk/dxerr9.h index 440bc3fcf63..6b42b8b2f8d 100644 --- a/sdk/include/dxsdk/dxerr9.h +++ b/sdk/include/dxsdk/dxerr9.h @@ -1,11 +1,11 @@ - #ifndef _DXERR9_H_ + +#ifndef _DXERR9_H_ #define _DXERR9_H_ #ifdef __cplusplus extern "C" { #endif - const char* WINAPI DXGetErrorString9A(HRESULT hr); const char* WINAPI DXGetErrorDescription9A(HRESULT hr); HRESULT WINAPI DXTraceA( const char* strFile, DWORD dwLine, HRESULT hr, const char* strMsg, BOOL bPopMsgBox ); @@ -24,8 +24,7 @@ HRESULT WINAPI DXTraceW( const char* strFile, DWORD dwLine, HRESULT hr, const WC #define DXTrace DXTraceA #endif - -#if defined(DEBUG) | defined(_DEBUG) +#if defined(DEBUG) || defined(_DEBUG) #define DXTRACE_MSG(str) DXTrace( __FILE__, (DWORD)__LINE__, 0, str, FALSE ) #define DXTRACE_ERR(str,hr) DXTrace( __FILE__, (DWORD)__LINE__, hr, str, FALSE ) #define DXTRACE_ERR_MSGBOX(str,hr) DXTrace( __FILE__, (DWORD)__LINE__, hr, str, TRUE ) @@ -35,10 +34,8 @@ HRESULT WINAPI DXTraceW( const char* strFile, DWORD dwLine, HRESULT hr, const WC #define DXTRACE_ERR_MSGBOX(str,hr) (hr) #endif - #ifdef __cplusplus } #endif #endif - -- 2.17.1