Fix MSVC errors

This commit is contained in:
2025-12-15 21:48:30 +00:00
parent 05b7cfbbea
commit e16abc2459
3 changed files with 4 additions and 6 deletions

View File

@@ -9,9 +9,7 @@
#ifdef WAPP_PLATFORM_CPP
BEGIN_C_LINKAGE
#endif // !WAPP_PLATFORM_CPP
#ifdef WAPP_PLATFORM_CPP
#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})
@@ -21,7 +19,7 @@ BEGIN_C_LINKAGE
typedef struct test_func_result TestFuncResult;
struct test_func_result {
Str8RO name;
Str8 name;
b8 passed;
#ifdef WAPP_PLATFORM_WINDOWS

View File

@@ -173,7 +173,7 @@ TestFuncResult test_i32_array_append_alloc(void) {
u64 index = 0;
b8 running = true;
while (running) {
i32 num = (i32)index;
num = (i32)index;
arr_ptr = wapp_array_append_alloc(i32, I32Array, &allocator, &array2, &num);
++index;

View File

@@ -262,8 +262,8 @@ TestFuncResult test_str8_equal(void) {
Str8RO s4 = wapp_str8_lit_ro("goodbye");
result = wapp_str8_equal(&s1, &s2) == false;
result = result && wapp_str8_equal(&s1, &s3) == true;
result = result && wapp_str8_equal(&s1, &s4) == false;
result = result && wapp_str8_equal(&s1, &s3) == (b8)true;
result = result && wapp_str8_equal(&s1, &s4) == (b8)false;
return wapp_tester_result(result);
}