Skip to content

Commit dcdc51c

Browse files
committed
Merge pull request #267 from tbeu/Patch-inttypes-on-MSVC
Make use of MSVC specific macros for format specifiers
2 parents a277ea7 + e3aa02b commit dcdc51c

File tree

1 file changed

+9
-1
lines changed

1 file changed

+9
-1
lines changed

src/objectc.c

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,15 @@
2020
#include <stdio.h>
2121
#include <string.h>
2222

23-
#if !defined(_MSC_VER) || _MSC_VER >= 1800
23+
#if defined(_MSC_VER)
24+
#if _MSC_VER >= 1800
25+
#include <inttypes.h>
26+
#else
27+
#define PRIu64 "I64u"
28+
#define PRIi64 "I64i"
29+
#define PRIi8 "i"
30+
#endif
31+
#else
2432
#include <inttypes.h>
2533
#endif
2634

0 commit comments

Comments
 (0)