这段程序有什么缺点???
//Log.h
class CLogInfo
{
public:
CLogInfo(_bstr_t finename)
{
wchar_t* p=wcsrchr((wchar_t*)finename,L'\\');
if(p!=NULL)
{
p++;
m_sFileName=p;
}
}
~CLogInfo()
{
}
private:
_bstr_t FileName;
};
#ifndef __COMERROR_H__
#define __COMERROR_H__
#include "Log.h"
#define COMTRY { CLogInfo __log(_T(__FILE__));COMHR __comHr; try
#define COMCATCH() catch (_com_error &ex)
#define ALLCATCH() catch(...)
#define REPORT() __log.Code=ex.Error();
#define REPORTH() __log.Code=ex.Error();return __log.Code;
#define REPORTV() __log.Code=ex.Error();return ;
#define RETURNV() return
#define RETURNE() return E_FAIL
#define RETURNH() return ex.Error()
#define COMEND }
#endif
问:这段宏定义如果带入程序中去会有哪些弊端?