mirror of
https://github.com/nim-lang/Nim.git
synced 2026-04-19 05:50:30 +00:00
abi check: prefer nim constant to enable, document
This commit is contained in:
@@ -460,10 +460,6 @@ typedef int Nim_and_C_compiler_disagree_on_target_architecture[sizeof(NI) == siz
|
||||
# include <sys/types.h>
|
||||
#endif
|
||||
|
||||
/* Compile with -t:-DNIM_CHECK_ABI to enable */
|
||||
#ifdef NIM_CHECK_ABI
|
||||
# define NIM_CHECK_SIZE(typ, sz) \
|
||||
/* Compile with -d:checkAbi and a sufficiently C11:ish compiler to enable */
|
||||
#define NIM_CHECK_SIZE(typ, sz) \
|
||||
_Static_assert(sizeof(typ) == sz, "Nim & C disagree on type size")
|
||||
#else
|
||||
# define NIM_CHECK_SIZE(typ, sz)
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user