mirror of
https://github.com/CPunch/Laika.git
synced 2025-09-27 04:10:08 +00:00
Fixed MSVC VLAs
This commit is contained in:
@@ -7,8 +7,8 @@
|
|||||||
|
|
||||||
/* microsoft strikes again with their lack of support for VLAs */
|
/* microsoft strikes again with their lack of support for VLAs */
|
||||||
#if _MSC_VER
|
#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);
|
#define ENDVLA(var) laikaM_free(var);
|
||||||
#else
|
#else
|
||||||
#define VLA(type, var, sz) type var[sz];
|
#define VLA(type, var, sz) type var[sz];
|
||||||
/* stubbed */
|
/* stubbed */
|
||||||
|
Reference in New Issue
Block a user