diff options
author | Paul Sokolovsky <pfalcon@users.sourceforge.net> | 2018-10-06 23:34:58 +0300 |
---|---|---|
committer | Damien George <damien.p.george@gmail.com> | 2018-12-10 14:40:43 +1100 |
commit | 38151f35c19751207a96e9a6c6a12d84e2e3fb88 (patch) | |
tree | fd3d07fa10a3321c8b9889b6c38856dd056d21ae /py | |
parent | 074597f17279b273f2135e9596aaf3a2e1926f4c (diff) |
extmod/moductypes: Add aliases for native C types.
SHORT, INT, LONG, LONGLONG, and unsigned (U*) variants are being defined.
This is done at compile using GCC-style predefined macros like
__SIZEOF_INT__. If the compiler doesn't have such defines, no such types
will be defined.
Diffstat (limited to 'py')
-rw-r--r-- | py/mpconfig.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/py/mpconfig.h b/py/mpconfig.h index e028ab989..f613f664a 100644 --- a/py/mpconfig.h +++ b/py/mpconfig.h @@ -1170,6 +1170,12 @@ typedef double mp_float_t; #define MICROPY_PY_UCTYPES (0) #endif +// Whether to provide SHORT, INT, LONG, etc. types in addition to +// exact-bitness types like INT16, INT32, etc. +#ifndef MICROPY_PY_UCTYPES_NATIVE_C_TYPES +#define MICROPY_PY_UCTYPES_NATIVE_C_TYPES (1) +#endif + #ifndef MICROPY_PY_UZLIB #define MICROPY_PY_UZLIB (0) #endif |