Always reserve padding for structs that need it
This commit is contained in:
@@ -10,7 +10,7 @@
|
||||
#ifdef WAPP_PLATFORM_CPP
|
||||
BEGIN_C_LINKAGE
|
||||
|
||||
#define wapp_tester_result(PASSED) (TestFuncResult{wapp_str8_lit_ro(__func__), PASSED})
|
||||
#define wapp_tester_result(PASSED) (TestFuncResult{wapp_str8_lit_ro(__func__), PASSED, {}})
|
||||
#else
|
||||
#define wapp_tester_result(PASSED) ((TestFuncResult){.name = wapp_str8_lit_ro(__func__), .passed = PASSED})
|
||||
#endif // !WAPP_PLATFORM_CPP
|
||||
@@ -22,9 +22,7 @@ struct TestFuncResult {
|
||||
Str8 name;
|
||||
b8 passed;
|
||||
|
||||
#ifdef WAPP_PLATFORM_WINDOWS
|
||||
wapp_misc_utils_padding_size(sizeof(Str8RO) + sizeof(b8));
|
||||
#endif // WAPP_PLATFORM_WINDOWS
|
||||
wapp_misc_utils_reserve_padding(sizeof(Str8) + sizeof(b8));
|
||||
};
|
||||
|
||||
typedef TestFuncResult(TestFunc)(void);
|
||||
|
||||
Reference in New Issue
Block a user