diff options
author | stijn <stinos@zoho.com> | 2015-12-18 10:20:33 +0100 |
---|---|---|
committer | Damien George <damien.p.george@gmail.com> | 2015-12-19 01:15:58 +0000 |
commit | 0a4eb4dbf2df34b9a2efcf55855b9db7c7132bf7 (patch) | |
tree | 0993e9e3535f652b55988e565350a649fb814668 /py/emitcommon.c | |
parent | b61336483b8b4729309f95d232306ced97b00840 (diff) | |
download | micropython-0a4eb4dbf2df34b9a2efcf55855b9db7c7132bf7.tar.gz micropython-0a4eb4dbf2df34b9a2efcf55855b9db7c7132bf7.zip |
py/mpprint: Fix printing of 64bit integers for 64bit windows builds
This makes all tests pass again for 64bit windows builds which would
previously fail for anything printing ranges (builtin_range/unpack1)
because they were printed as range( ld, ld ).
This is done by reusing the mp_vprintf implementation for MICROPY_OBJ_REPR_D
for 64bit windows builds (both msvc and mingw-w64) since the format specifier
used for 64bit integers is also %lld, or %llu for the unsigned version.
Note these specifiers used to be fetched from inttypes.h, which is the
C99 way of working with printf/scanf in a portable way, but mingw-w64
wants to be backwards compatible with older MS C runtimes and uses
the non-portable %I64i instead of %lld in inttypes.h, so remove the use
of said header again in mpconfig.h and define the specifiers manually.
Diffstat (limited to 'py/emitcommon.c')
0 files changed, 0 insertions, 0 deletions