added freeMem argument in safethrow and try, fixed throw_wrongchar
This commit is contained in:
@@ -45,10 +45,11 @@ char* __unknownErr( );
|
||||
)(E)
|
||||
|
||||
#define throw(E) __EXIT(((char*)__genErrMsg((__stringify_err(E)), __FILE__,__LINE__,__func__)))
|
||||
#define safethrow(E) __RETURN_EXCEPTION(((char*)__genErrMsg((__stringify_err(E)), __FILE__,__LINE__,__func__)))
|
||||
#define safethrow(E, FREEMEM) FREEMEM; __RETURN_EXCEPTION(((char*)__genErrMsg((__stringify_err(E)), __FILE__,__LINE__,__func__)))
|
||||
|
||||
|
||||
#define try(_funcCall, _rezult) Maybe _rezult=_funcCall; if(_rezult.errmsg){\
|
||||
#define try(_funcCall, _rezult, freeMem) Maybe _rezult=_funcCall; if(_rezult.errmsg){\
|
||||
freeMem;\
|
||||
_rezult.errmsg=__extendErrMsg(_rezult.errmsg, __FILE__,__LINE__,__func__);\
|
||||
return _rezult;\
|
||||
}else
|
||||
|
||||
Reference in New Issue
Block a user