Merge pull request #415 from DuncanSparks/alloca_fix

Fix alloca.h error in Defs.h
pull/445/head
Marc 2020-08-16 20:16:36 +01:00 committed by GitHub
commit 16000199c5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 1 deletions

View File

@ -62,8 +62,10 @@ enum class Error {
#include <GodotGlobal.hpp> #include <GodotGlobal.hpp>
// alloca() is non-standard. When using MSVC, it's in malloc.h. // alloca() is non-standard. When using MSVC, it's in malloc.h.
#if defined(__linux__) || defined(__APPLE__) || defined(__MINGW32__) #if defined(__linux__) || defined(__APPLE__)
#include <alloca.h> #include <alloca.h>
#else
#include <malloc.h>
#endif #endif
typedef float real_t; typedef float real_t;