vrecko
virtual reality framework
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
HelperMacros.h File Reference
#include <vrecko/Logger.h>

Go to the source code of this file.

Macros

#define BFAILGOTO(Function)   { if (!(Function)) { OUTPUTSTR3("\n%s(%d): An error occured!", __FILE__, __LINE__); goto FuncFailed; } }
 
#define BFAILGOTO_TEXT(Function, TextFunc)   { if (!(Function)) { { OUTPUTSTR3("\n%s(%d): Following error occured:", __FILE__, __LINE__); TextFunc; } goto FuncFailed; } }
 
#define BFAILRET(Function)   { if (!(Function)) { OUTPUTSTR3("\n%s(%d): An error occured!", __FILE__, __LINE__); return false; } }
 
#define BFAILRET_TEXT(Function, TextFunc)   { if (!(Function)) { { OUTPUTSTR3("\n%s(%d): Following error occured:", __FILE__, __LINE__); TextFunc; } return false; } }
 
#define SAFE_DELETE(p)   { if(p) { delete (p); (p)=NULL; } }
 
#define SAFE_FREE(p)   { if(p) { free (p); (p)=NULL; } }
 

Macro Definition Documentation

#define BFAILGOTO (   Function)    { if (!(Function)) { OUTPUTSTR3("\n%s(%d): An error occured!", __FILE__, __LINE__); goto FuncFailed; } }
#define BFAILGOTO_TEXT (   Function,
  TextFunc 
)    { if (!(Function)) { { OUTPUTSTR3("\n%s(%d): Following error occured:", __FILE__, __LINE__); TextFunc; } goto FuncFailed; } }
#define BFAILRET (   Function)    { if (!(Function)) { OUTPUTSTR3("\n%s(%d): An error occured!", __FILE__, __LINE__); return false; } }
#define BFAILRET_TEXT (   Function,
  TextFunc 
)    { if (!(Function)) { { OUTPUTSTR3("\n%s(%d): Following error occured:", __FILE__, __LINE__); TextFunc; } return false; } }
#define SAFE_DELETE (   p)    { if(p) { delete (p); (p)=NULL; } }
#define SAFE_FREE (   p)    { if(p) { free (p); (p)=NULL; } }