Fix MSVC errors
This commit is contained in:
@@ -9,9 +9,7 @@
|
|||||||
|
|
||||||
#ifdef WAPP_PLATFORM_CPP
|
#ifdef WAPP_PLATFORM_CPP
|
||||||
BEGIN_C_LINKAGE
|
BEGIN_C_LINKAGE
|
||||||
#endif // !WAPP_PLATFORM_CPP
|
|
||||||
|
|
||||||
#ifdef WAPP_PLATFORM_CPP
|
|
||||||
#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
|
#else
|
||||||
#define wapp_tester_result(PASSED) ((TestFuncResult){.name = wapp_str8_lit_ro(__func__), .passed = PASSED})
|
#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;
|
typedef struct test_func_result TestFuncResult;
|
||||||
struct test_func_result {
|
struct test_func_result {
|
||||||
Str8RO name;
|
Str8 name;
|
||||||
b8 passed;
|
b8 passed;
|
||||||
|
|
||||||
#ifdef WAPP_PLATFORM_WINDOWS
|
#ifdef WAPP_PLATFORM_WINDOWS
|
||||||
|
|||||||
@@ -173,7 +173,7 @@ TestFuncResult test_i32_array_append_alloc(void) {
|
|||||||
u64 index = 0;
|
u64 index = 0;
|
||||||
b8 running = true;
|
b8 running = true;
|
||||||
while (running) {
|
while (running) {
|
||||||
i32 num = (i32)index;
|
num = (i32)index;
|
||||||
arr_ptr = wapp_array_append_alloc(i32, I32Array, &allocator, &array2, &num);
|
arr_ptr = wapp_array_append_alloc(i32, I32Array, &allocator, &array2, &num);
|
||||||
|
|
||||||
++index;
|
++index;
|
||||||
|
|||||||
@@ -262,8 +262,8 @@ TestFuncResult test_str8_equal(void) {
|
|||||||
Str8RO s4 = wapp_str8_lit_ro("goodbye");
|
Str8RO s4 = wapp_str8_lit_ro("goodbye");
|
||||||
|
|
||||||
result = wapp_str8_equal(&s1, &s2) == false;
|
result = wapp_str8_equal(&s1, &s2) == false;
|
||||||
result = result && wapp_str8_equal(&s1, &s3) == true;
|
result = result && wapp_str8_equal(&s1, &s3) == (b8)true;
|
||||||
result = result && wapp_str8_equal(&s1, &s4) == false;
|
result = result && wapp_str8_equal(&s1, &s4) == (b8)false;
|
||||||
|
|
||||||
return wapp_tester_result(result);
|
return wapp_tester_result(result);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user