00001 // -*- c++ -*- 00002 // = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = 00003 00004 // O S C L _ E R R O R _ I M P _ F A T A L E R R O R 00005 00006 // = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = 00007 00018 #ifndef OSCL_ERROR_IMP_FATALERROR_H_INCLUDED 00019 #define OSCL_ERROR_IMP_FATALERROR_H_INCLUDED 00020 00021 // Implementation File for Leave using system fatal error. 00022 00023 //Fatal error implementation for compilers without C++ exceptions. 00024 //This implementation is very limited. Leave conditions 00025 //just cause fatal program errors. There is no way to catch or trap 00026 //any Leave. 00027 #ifndef OSCL_ASSERT_H_INCLUDED 00028 #include "oscl_assert.h" 00029 #endif 00030 00031 //Leave just calls a system fatal error. 00032 #define PVError_DoLeave() _OSCL_Abort() 00033 00034 //_PV_TRAP 00035 //_r is leave code, _s is statements. 00036 //this macro isn't really functional since any 00037 //leave will abort the program, but it's needed 00038 //to compile. 00039 #define _PV_TRAP(__r,__s) \ 00040 __r=OsclErrNone;\ 00041 {__s;} 00042 00043 //_PV_TRAP_NO_TLS 00044 //_r is leave code, _s is statements. 00045 //this macro isn't really functional since any 00046 //leave will abort the program, but it's needed 00047 //to compile. 00048 #define _PV_TRAP_NO_TLS(__tr,__r,__s) \ 00049 __r=OsclErrNone;\ 00050 {__s;} 00051 00052 00053 00054 #endif // OSCL_ERROR_IMP_FATALERROR_H_INCLUDED 00055