mirror of
https://github.com/zeldaret/st
synced 2026-05-30 08:56:35 -04:00
69ef244371
* merge headers from nitro decomp * cleanup: use inlines from g2.h and gx.h when changing registers * cleanup: remove externs declarations in source files
39 lines
680 B
C
39 lines
680 B
C
#ifndef _C_STDDEF_H
|
|
#define _C_STDDEF_H
|
|
|
|
#ifdef __cplusplus
|
|
extern "C" {
|
|
#endif
|
|
|
|
#ifndef NULL
|
|
#define NULL 0
|
|
#endif
|
|
|
|
#ifndef nullptr
|
|
#define nullptr 0
|
|
#endif
|
|
|
|
#define offsetof(ST, M) ((size_t) &(((ST *) 0)->M))
|
|
|
|
typedef signed long intptr_t;
|
|
typedef unsigned long uintptr_t;
|
|
typedef intptr_t ptrdiff_t;
|
|
|
|
// gcc want size_t to be an unsigned int, and metrowerks want it to be an unsigned long (oh and vscode also doesn't
|
|
// agree....................)
|
|
#if defined(__MWERKS__) || defined(__INTELLISENSE__)
|
|
typedef unsigned long size_t;
|
|
#else
|
|
typedef unsigned int size_t;
|
|
#endif
|
|
|
|
#ifndef __cplusplus
|
|
typedef unsigned short wchar_t;
|
|
#endif
|
|
|
|
#ifdef __cplusplus
|
|
}
|
|
#endif
|
|
|
|
#endif
|