summaryrefslogtreecommitdiff
path: root/py/objarray.c
diff options
context:
space:
mode:
authorPaul Sokolovsky <pfalcon@users.sourceforge.net>2014-06-27 20:39:09 +0300
committerPaul Sokolovsky <pfalcon@users.sourceforge.net>2014-06-27 21:02:04 +0300
commitcb78f862cb595bf1e4f164869fe44a4ee7755a55 (patch)
tree3b73f937959315b5aab4c5eebe9f5c27c4a24b66 /py/objarray.c
parent0a1ea402739f400bb477e00dbc21c97feaec4fea (diff)
py: Allow to disable array module and bytearray type.
array.array and bytearray share big deal of code, so to get real savings, both need to be disabled.
Diffstat (limited to 'py/objarray.c')
-rw-r--r--py/objarray.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/py/objarray.c b/py/objarray.c
index 05821e8de..b13df2bdb 100644
--- a/py/objarray.c
+++ b/py/objarray.c
@@ -37,6 +37,8 @@
#include "runtime.h"
#include "binary.h"
+#if MICROPY_PY_ARRAY || MICROPY_PY_BUILTINS_BYTEARRAY
+
typedef struct _mp_obj_array_t {
mp_obj_base_t base;
machine_uint_t typecode : 8;
@@ -310,3 +312,5 @@ STATIC mp_obj_t array_iterator_new(mp_obj_t array_in) {
o->cur = 0;
return o;
}
+
+#endif // MICROPY_PY_ARRAY || MICROPY_PY_BUILTINS_BYTEARRAY