diff --git a/src/KingSystem/Utils/HeapUtil.h b/src/KingSystem/Utils/HeapUtil.h index bc6730c6..b5629aa7 100644 --- a/src/KingSystem/Utils/HeapUtil.h +++ b/src/KingSystem/Utils/HeapUtil.h @@ -102,7 +102,7 @@ sead::Heap* getCurrentHeap(); sead::Heap* getDebugHeap(); sead::Heap* getDebugHeap2(); -[[gnu::always_inline]] inline sead::Heap* tryCreateDualHeap(sead::Heap* parent) { +KSYS_ALWAYS_INLINE inline sead::Heap* tryCreateDualHeap(sead::Heap* parent) { size_t size; if (const auto* parent_ex = sead::DynamicCast(parent)) { diff --git a/src/KingSystem/Utils/Types.h b/src/KingSystem/Utils/Types.h index cc2b6e4b..941ec17c 100644 --- a/src/KingSystem/Utils/Types.h +++ b/src/KingSystem/Utils/Types.h @@ -7,3 +7,8 @@ #else #define KSYS_CHECK_SIZE_NX150(CLASS, SIZE) static_assert(sizeof(CLASS) == SIZE) #endif + +#ifdef __GNUC__ +#define KSYS_ALWAYS_INLINE [[gnu::always_inline]] +#define KSYS_VISIBILITY_HIDDEN [[gnu::visibility("hidden")]] +#endif