diff options
Diffstat (limited to 'dev/LibSCI/Macros.h')
| -rw-r--r-- | dev/LibSCI/Macros.h | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/dev/LibSCI/Macros.h b/dev/LibSCI/Macros.h index 5f4253de..62d522c9 100644 --- a/dev/LibSCI/Macros.h +++ b/dev/LibSCI/Macros.h @@ -54,3 +54,18 @@ typedef IOObject FSObject; typedef SCIObject DLLObject; typedef SCIObject ThreadObject; typedef SCIObject SocketObject; + +#ifdef __cplusplus +typedef decltype(nullptr) nullPtr; +typedef decltype(nullptr) NullPtr; +#endif + +EXTERN_C void _rtl_assert(Bool expr, const Char* origin); + +#define MUST_PASS(X) _rtl_assert(X, __FILE__) + +#ifndef ARRAY_SIZE +#define ARRAY_SIZE(a) \ + (((sizeof(a) / sizeof(*(a))) / \ + (static_cast<Kernel::Size>(!(sizeof(a) % sizeof(*(a))))))) +#endif
\ No newline at end of file |
