| @@ -83,12 +83,12 @@ | |||||
| } while (0); | } while (0); | ||||
| // If expr is not GRAPH_SUCCESS, print the log and return FAILED | // If expr is not GRAPH_SUCCESS, print the log and return FAILED | ||||
| #define GE_CHK_GRAPH_STATUS_RET(expr, ...) \ | |||||
| do { \ | |||||
| if ((expr) != ge::GRAPH_SUCCESS) { \ | |||||
| DOMI_LOGE(__VA_ARGS__); \ | |||||
| return FAILED; \ | |||||
| } \ | |||||
| #define GE_CHK_GRAPH_STATUS_RET(expr, ...) \ | |||||
| do { \ | |||||
| if ((expr) != ge::GRAPH_SUCCESS) { \ | |||||
| DOMI_LOGE(__VA_ARGS__); \ | |||||
| return FAILED; \ | |||||
| } \ | |||||
| } while (0); | } while (0); | ||||
| // If expr is not SUCCESS, print the log and execute a custom statement | // If expr is not SUCCESS, print the log and execute a custom statement | ||||
| @@ -99,13 +99,13 @@ | |||||
| } while (0); | } while (0); | ||||
| // If expr is not true, print the log and return the specified status | // If expr is not true, print the log and return the specified status | ||||
| #define GE_CHK_BOOL_RET_STATUS(expr, _status, ...) \ | |||||
| do { \ | |||||
| bool b = (expr); \ | |||||
| if (!b) { \ | |||||
| GELOGE(_status, __VA_ARGS__); \ | |||||
| return _status; \ | |||||
| } \ | |||||
| #define GE_CHK_BOOL_RET_STATUS(expr, _status, ...) \ | |||||
| do { \ | |||||
| bool b = (expr); \ | |||||
| if (!b) { \ | |||||
| GELOGE(_status, __VA_ARGS__); \ | |||||
| return _status; \ | |||||
| } \ | |||||
| } while (0); | } while (0); | ||||
| // If expr is not true, print the log and return the specified status | // If expr is not true, print the log and return the specified status | ||||
| @@ -259,7 +259,6 @@ | |||||
| ErrorManager::GetInstance().ATCReportErrMessage("E10043", {"reason"}, {errormsg}); \ | ErrorManager::GetInstance().ATCReportErrMessage("E10043", {"reason"}, {errormsg}); \ | ||||
| } | } | ||||
| #define GE_CHK_LOG_AND_ERRORMSG(expr, _status, errormsg) \ | #define GE_CHK_LOG_AND_ERRORMSG(expr, _status, errormsg) \ | ||||
| do { \ | do { \ | ||||
| bool b = (expr); \ | bool b = (expr); \ | ||||