summaryrefslogtreecommitdiffstats
path: root/core/error_macros.h
diff options
context:
space:
mode:
authorRémi Verschelde <rverschelde@gmail.com>2020-03-12 22:02:18 +0100
committerGitHub <noreply@github.com>2020-03-12 22:02:18 +0100
commit36a414eb03608dcef1444230e1c29790bde9c949 (patch)
tree6c5147f6beae3e21fcb6af35ca131ced4b418811 /core/error_macros.h
parent3c376a898ae6f4b6332d732d29c44d090978b887 (diff)
parent1c2f2a805d99c92e0a8b72dae462018b0bd277c4 (diff)
downloadredot-engine-36a414eb03608dcef1444230e1c29790bde9c949.tar.gz
Merge pull request #36994 from akien-mga/typedefs-cleanup
typedefs: Cleanup unused macros and unnecessary checks
Diffstat (limited to 'core/error_macros.h')
-rw-r--r--core/error_macros.h20
1 files changed, 10 insertions, 10 deletions
diff --git a/core/error_macros.h b/core/error_macros.h
index e4d7609e04..8818dcbe77 100644
--- a/core/error_macros.h
+++ b/core/error_macros.h
@@ -502,11 +502,11 @@ void _err_print_index_error(const char *p_function, const char *p_file, int p_li
*
* The current function returns `m_retval`.
*/
-#define ERR_FAIL_V(m_retval) \
- if (1) { \
- _err_print_error(FUNCTION_STR, __FILE__, __LINE__, "Method/Function Failed, returning: " __STR(m_retval)); \
- return m_retval; \
- } else \
+#define ERR_FAIL_V(m_retval) \
+ if (1) { \
+ _err_print_error(FUNCTION_STR, __FILE__, __LINE__, "Method/Function Failed, returning: " _STR(m_retval)); \
+ return m_retval; \
+ } else \
((void)0)
/**
@@ -515,11 +515,11 @@ void _err_print_index_error(const char *p_function, const char *p_file, int p_li
*
* Prints `m_msg`, and the current function returns `m_retval`.
*/
-#define ERR_FAIL_V_MSG(m_retval, m_msg) \
- if (1) { \
- _err_print_error(FUNCTION_STR, __FILE__, __LINE__, "Method/Function Failed, returning: " __STR(m_retval), DEBUG_STR(m_msg)); \
- return m_retval; \
- } else \
+#define ERR_FAIL_V_MSG(m_retval, m_msg) \
+ if (1) { \
+ _err_print_error(FUNCTION_STR, __FILE__, __LINE__, "Method/Function Failed, returning: " _STR(m_retval), DEBUG_STR(m_msg)); \
+ return m_retval; \
+ } else \
((void)0)
/**