mirror of
https://github.com/zeldaret/ph
synced 2026-05-23 23:05:17 -04:00
e9ffe114a9
* Delink .text for ActorItemSeller, ActorBeedle, ActorTetra * Delink .text for ActorCharacterBase, ActorCharacter, ActorGenericCharacter * Define classes ActorCharacterBase, ActorCharacter, ActorGenericCharacter * Don't define `override` macro during intellisense/clangd * Define symbols for ActorCharacter, ActorCharacterBase, ActorGenericCharacter * Define classes and symbols for ActorItemSeller, ActorBeedle, ActorTetra * Fix duplicate symbol
26 lines
798 B
C
26 lines
798 B
C
#ifndef PH_GLOBAL_H
|
|
#define PH_GLOBAL_H
|
|
|
|
#define ARRAY_LEN_U(arr) (u32)((sizeof(arr) / sizeof(*arr)))
|
|
#define ARRAY_LEN(arr) (s32)(sizeof(arr) / sizeof(*arr))
|
|
|
|
// Prevent the IDE from reporting errors that the compiler/linker won't report
|
|
#if defined(__INTELLISENSE__) || (__clang__)
|
|
#else
|
|
// `override` was added in C++11 before the DS, so we only use the keyword to indicate overriden functions
|
|
#define override
|
|
#endif
|
|
|
|
#define ARM _Pragma("thumb off")
|
|
#define THUMB _Pragma("thumb on")
|
|
|
|
// Puts variables in the DTCM module by using #pragma section dtcm begin|end
|
|
#pragma define_section dtcm ".dtcm" \
|
|
".dtcm"
|
|
|
|
// Define .sbss variables by using #pragma section sbss begin|end
|
|
#pragma define_section sbss ".data" \
|
|
".sbss"
|
|
|
|
#endif
|