diff options
author | Nikolay Korolev <nickvnuk@gmail.com> | 2020-08-08 12:08:21 +0200 |
---|---|---|
committer | Nikolay Korolev <nickvnuk@gmail.com> | 2020-08-08 12:08:21 +0200 |
commit | 9bc105c92346494bc4c36bcebd0a4a86bf9d6a86 (patch) | |
tree | b0582e41c8bc4d5fa0979d8a453b0a2d128f012c /src/core/common.h | |
parent | submodules? (diff) | |
parent | Merge pull request #680 from ShFil119/actions (diff) | |
download | re3-9bc105c92346494bc4c36bcebd0a4a86bf9d6a86.tar re3-9bc105c92346494bc4c36bcebd0a4a86bf9d6a86.tar.gz re3-9bc105c92346494bc4c36bcebd0a4a86bf9d6a86.tar.bz2 re3-9bc105c92346494bc4c36bcebd0a4a86bf9d6a86.tar.lz re3-9bc105c92346494bc4c36bcebd0a4a86bf9d6a86.tar.xz re3-9bc105c92346494bc4c36bcebd0a4a86bf9d6a86.tar.zst re3-9bc105c92346494bc4c36bcebd0a4a86bf9d6a86.zip |
Diffstat (limited to 'src/core/common.h')
-rw-r--r-- | src/core/common.h | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/src/core/common.h b/src/core/common.h index ebb3acb0..e876c4ec 100644 --- a/src/core/common.h +++ b/src/core/common.h @@ -89,6 +89,16 @@ typedef uint16_t wchar; #include <rpskin.h> #endif +#ifdef __GNUC__ +#define TYPEALIGN(n) __attribute__ ((aligned (n))) +#else +#ifdef _MSC_VER +#define TYPEALIGN(n) __declspec(align(n)) +#else +#define TYPEALIGN(n) // unknown compiler...ignore +#endif +#endif + #define ALIGNPTR(p) (void*)((((uintptr)(void*)p) + sizeof(void*)-1) & ~(sizeof(void*)-1)) // PDP-10 like byte functions |