Hoard
Hoard copied to clipboard
Build issue on Visual Studio 2019
Hello,
There is a build issue in the file source/libhoard.cpp:119
:
source\libhoard.cpp(119): error C2065: 'flatten': undeclared identifier
source\libhoard.cpp(119): error C2146: syntax error: missing ';' before identifier 'xxmalloc'
source\libhoard.cpp(119): error C3646: '__attribute__': unknown override specifier
source\libhoard.cpp(119): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
source\libhoard.cpp(119): error C2556: 'int xxmalloc(size_t)': overloaded function differs only by return type from 'void *xxmalloc(size_t)'
D:\git-repositories\Hoard\src\Heap-Layers/wrappers/generic-memalign.cpp(15): note: see declaration of 'xxmalloc'
source\libhoard.cpp(119): error C2040: 'xxmalloc': 'int (size_t)' differs in levels of indirection from 'void *(size_t)'
source\libhoard.cpp(119): error C2059: syntax error: '('
source\libhoard.cpp(119): error C2143: syntax error: missing ')' before '('
source\libhoard.cpp(119): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
source\libhoard.cpp(119): error C2059: syntax error: ')'
source\libhoard.cpp(119): error C2146: syntax error: missing ';' before identifier '__attribute'
source\libhoard.cpp(121): error C2143: syntax error: missing ';' before '{'
source\libhoard.cpp(121): error C2447: '{': missing function header (old-style formal list?)
AFAIK, __attribute__
is not supported by MSVC. The DLL can be built without them, but I am not sure this is fine. Maybe a MSVC equivalent should be used instead.
Thank you.
I am getting the same errors. Found this on SO, but didn't know what to do with it. Any help appreciated :)
I am getting exactly the same error! (Windows 10 Pro, MS VC++ 2017)