mirror of
https://github.com/yshui/picom.git
synced 2024-11-18 13:55:36 -05:00
test.h: silence gcc warnings about unused results
This is not perfect, and gcc warnings are often unpredictable (generally what you don't want warnings to be). But seems to work for now. Signed-off-by: Yuxuan Shui <yshuiv7@gmail.com>
This commit is contained in:
parent
7094d7a906
commit
6e63489bd8
1 changed files with 2 additions and 6 deletions
|
@ -222,12 +222,8 @@ static inline void __attribute__((constructor(102))) run_tests(void) {
|
|||
|
||||
#define TEST_CASE(name) static void __attribute__((unused)) __test_h_##name(void)
|
||||
|
||||
#define TEST_EQUAL(a, b) \
|
||||
(void)(a); \
|
||||
(void)(b)
|
||||
#define TEST_NOTEQUAL(a, b) \
|
||||
(void)(a); \
|
||||
(void)(b)
|
||||
#define TEST_EQUAL(a, b) (void)((a) == (b))
|
||||
#define TEST_NOTEQUAL(a, b) (void)((a) != (b))
|
||||
#define TEST_TRUE(a) (void)(a)
|
||||
#define TEST_STREQUAL(a, b) \
|
||||
(void)(a); \
|
||||
|
|
Loading…
Reference in a new issue