Skip to content

Build issue on Visual Studio 2019 #65

@zephyr111

Description

@zephyr111

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.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions