Fix missing newline in unit assert messages

This commit is contained in:
2024-04-14 13:53:50 +03:00
parent ac5df0ebe9
commit 7b97af5898

View File

@@ -7,14 +7,14 @@ typedef int (*bh_unit_cb_t)(void);
#define bh_unit_assert(e) \ #define bh_unit_assert(e) \
if (!(e)) { \ if (!(e)) { \
printf("%s:%d\t%s", __FILE__, __LINE__, #e); \ printf("%s:%d\t%s\n", __FILE__, __LINE__, #e); \
return -1; \ return -1; \
} }
#define bh_unit_assert_delta(x, y, e) \ #define bh_unit_assert_delta(x, y, e) \
if ((((x)>(y))?((x)-(y)):((y)-(x)))>(e)) { \ if ((((x)>(y))?((x)-(y)):((y)-(x)))>(e)) { \
printf("%s:%d\t%s", __FILE__, __LINE__, #x " == " #y); \ printf("%s:%d\t%s\n", __FILE__, __LINE__, #x " == " #y); \
return -1; \ return -1; \
} }