mirror of
https://github.com/CPunch/Laika.git
synced 2024-11-24 13:31:05 +00:00
Fixed MSVC VLAs
This commit is contained in:
parent
a8c1b44bb9
commit
dfdcb04608
@ -7,7 +7,7 @@
|
||||
|
||||
/* microsoft strikes again with their lack of support for VLAs */
|
||||
#if _MSC_VER
|
||||
#define VLA(type, var, sz) type var = laikaM_malloc(sizeof(type)*sz);
|
||||
#define VLA(type, var, sz) type *var = laikaM_malloc(sizeof(type)*sz);
|
||||
#define ENDVLA(var) laikaM_free(var);
|
||||
#else
|
||||
#define VLA(type, var, sz) type var[sz];
|
||||
|
Loading…
Reference in New Issue
Block a user