changeset 578:ac2947ac9ef8

Define PRI*_SIZE_T from PRIu32/64 based on platform, this is cleaner and avoids issues on MINGW64.
author Matti Hamalainen <ccr@tnsp.org>
date Thu, 09 Jan 2020 18:29:10 +0200
parents 70d44ba005ac
children c054e5831dfb
files th_types.h
diffstat 1 files changed, 6 insertions(+), 6 deletions(-) [+]
line wrap: on
line diff
--- a/th_types.h	Thu Jan 09 18:27:48 2020 +0200
+++ b/th_types.h	Thu Jan 09 18:29:10 2020 +0200
@@ -79,9 +79,9 @@
 #    define PRIi64        "lli"
 #    define PRIo64        "llo"
 #  endif
-#  define PRIu_SIZE_T     "u"
-#  define PRId_SSIZE_T    "d"
-#  define PRIx_SIZE_T     "x"
+#  define PRIu_SIZE_T     PRIu32
+#  define PRId_SSIZE_T    PRId32
+#  define PRIx_SIZE_T     PRIx32
 #  ifndef TH_PTRSIZE
 #    define TH_PTRSIZE 32
 #  endif
@@ -103,9 +103,9 @@
 #    define PRIi64        "li"
 #    define PRIo64        "lo"
 #  endif
-#  define PRIu_SIZE_T     "lu"
-#  define PRId_SSIZE_T    "ld"
-#  define PRIx_SIZE_T     "lx"
+#  define PRIu_SIZE_T     PRIu64
+#  define PRId_SSIZE_T    PRId64
+#  define PRIx_SIZE_T     PRIx64
 #  ifndef TH_PTRSIZE
 #    define TH_PTRSIZE 64
 #  endif