Luckily, it seems all archs use for them the same types as size_t & ssize_t. Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@xxxxxxxxx> --- lib.c | 2 ++ validation/preprocessor/predef.c | 2 ++ 2 files changed, 4 insertions(+) diff --git a/lib.c b/lib.c index 605f9edd5..b030e17e4 100644 --- a/lib.c +++ b/lib.c @@ -1262,6 +1262,8 @@ static void predefined_macros(void) predefined_sizeof("INT128", "", 128); + predefined_ctype("INTPTR", ssize_t_ctype, PTYPE_MAX|PTYPE_TYPE|PTYPE_WIDTH); + predefined_ctype("UINTPTR", size_t_ctype, PTYPE_MAX|PTYPE_TYPE); predefined_ctype("PTRDIFF", ssize_t_ctype, PTYPE_ALL_T|PTYPE_TYPE); predefined_ctype("SIZE", size_t_ctype, PTYPE_ALL_T|PTYPE_TYPE); predefined_ctype("POINTER", &ptr_ctype, PTYPE_SIZEOF); diff --git a/validation/preprocessor/predef.c b/validation/preprocessor/predef.c index 298bdd93c..df0944b33 100644 --- a/validation/preprocessor/predef.c +++ b/validation/preprocessor/predef.c @@ -17,6 +17,8 @@ int test(void) TEST_SMAX(INT, int); TEST_SMAX(LONG, long); TEST_SMAX(LONG_LONG, long long); + TEST_SMAX(INTPTR, __INTPTR_TYPE__); + TEST_UMAX(UINTPTR, __UINTPTR_TYPE__); TEST_SMAX(PTRDIFF, __PTRDIFF_TYPE__); TEST_UMAX(SIZE, __SIZE_TYPE__); -- 2.19.0