diff options
author | Damien George <damien.p.george@gmail.com> | 2014-02-11 21:58:08 +0000 |
---|---|---|
committer | Damien George <damien.p.george@gmail.com> | 2014-02-11 21:58:08 +0000 |
commit | 9d324b0ac7e4904c8237cf9fa96ba41777c4a0a1 (patch) | |
tree | 353cabb22f72c305685a0526262b9676e8d00eda | |
parent | 323f39a2b383ba1f4b65f5cd786a2531589d1677 (diff) | |
download | micropython-9d324b0ac7e4904c8237cf9fa96ba41777c4a0a1.tar.gz micropython-9d324b0ac7e4904c8237cf9fa96ba41777c4a0a1.zip |
stm: Add specific UINT_FMT and INT_FMT.
For some reason, STM port, while it's 32 bit, needs %lu and %ld for
printing machine_uint_t and machine_int_t.
-rw-r--r-- | stm/mpconfigport.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/stm/mpconfigport.h b/stm/mpconfigport.h index 1d79243f9b..51e4bb9a82 100644 --- a/stm/mpconfigport.h +++ b/stm/mpconfigport.h @@ -13,6 +13,9 @@ #define BYTES_PER_WORD (4) +#define UINT_FMT "%lu" +#define INT_FMT "%ld" + typedef int32_t machine_int_t; // must be pointer size typedef uint32_t machine_uint_t; // must be pointer size typedef void *machine_ptr_t; // must be of pointer size |