summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorStanislaw Halik <sthalik@misaki.pl>2022-11-13 07:35:58 +0100
committerStanislaw Halik <sthalik@misaki.pl>2022-11-13 07:35:58 +0100
commitb79154186967389463eb6aeb88fbb53bd8a5034c (patch)
tree1728c27fe5b15cd63b05fd9e42bbd79f484240e0
parent4ae9e6ca82fda9fb0804a3d110baaddcdaedfb4b (diff)
only need to #define alloca on msvc
-rw-r--r--compat/alloca.hpp8
1 files changed, 5 insertions, 3 deletions
diff --git a/compat/alloca.hpp b/compat/alloca.hpp
index 97969a55..ac4b6996 100644
--- a/compat/alloca.hpp
+++ b/compat/alloca.hpp
@@ -1,8 +1,10 @@
#pragma once
#ifdef _WIN32
-# include <malloc.h>
-# define alloca _alloca
+#include <malloc.h>
+#ifdef _MSC_VER
+#define alloca _alloca
+#endif
#else
-# include <alloca.h>
+#include <alloca.h>
#endif