py: Fix configurability of builtin slice.
diff --git a/py/obj.h b/py/obj.h
index e7c044d..7c83715 100644
--- a/py/obj.h
+++ b/py/obj.h
@@ -568,7 +568,9 @@
 } mp_bound_slice_t;
 
 void mp_seq_multiply(const void *items, uint item_sz, uint len, uint times, void *dest);
+#if MICROPY_PY_BUILTINS_SLICE
 bool mp_seq_get_fast_slice_indexes(machine_uint_t len, mp_obj_t slice, mp_bound_slice_t *indexes);
+#endif
 #define mp_seq_copy(dest, src, len, item_t) memcpy(dest, src, len * sizeof(item_t))
 #define mp_seq_cat(dest, src1, len1, src2, len2, item_t) { memcpy(dest, src1, (len1) * sizeof(item_t)); memcpy(dest + (len1), src2, (len2) * sizeof(item_t)); }
 bool mp_seq_cmp_bytes(int op, const byte *data1, uint len1, const byte *data2, uint len2);
diff --git a/py/objarray.c b/py/objarray.c
index 91fcec6..44fbf2f 100644
--- a/py/objarray.c
+++ b/py/objarray.c
@@ -169,7 +169,9 @@
         return MP_OBJ_NULL; // op not supported
     } else {
         mp_obj_array_t *o = self_in;
-        if (MP_OBJ_IS_TYPE(index_in, &mp_type_slice)) {
+        if (0) {
+#if MICROPY_PY_BUILTINS_SLICE
+        } else if (MP_OBJ_IS_TYPE(index_in, &mp_type_slice)) {
             if (value != MP_OBJ_SENTINEL) {
                 // Only getting a slice is suported so far, not assignment
                 // TODO: confirmed that both bytearray and array.array support
@@ -187,6 +189,7 @@
             byte *p = o->items;
             memcpy(res->items, p + slice.start * sz, (slice.stop - slice.start) * sz);
             return res;
+#endif
         } else {
             uint index = mp_get_index(o->base.type, o->len, index_in, false);
             if (value == MP_OBJ_SENTINEL) {
diff --git a/py/runtime.c b/py/runtime.c
index cb4d16b..ecaf40d 100644
--- a/py/runtime.c
+++ b/py/runtime.c
@@ -1185,7 +1185,9 @@
     mp_import_name,
     mp_import_from,
     mp_import_all,
+#if MICROPY_PY_BUILTINS_SLICE
     mp_obj_new_slice,
+#endif
     mp_unpack_sequence,
     mp_unpack_ex,
 };
diff --git a/py/runtime0.h b/py/runtime0.h
index 1d1f9d7..eea5782 100644
--- a/py/runtime0.h
+++ b/py/runtime0.h
@@ -127,7 +127,9 @@
     MP_F_IMPORT_NAME,
     MP_F_IMPORT_FROM,
     MP_F_IMPORT_ALL,
+#if MICROPY_PY_BUILTINS_SLICE
     MP_F_NEW_SLICE,
+#endif
     MP_F_UNPACK_SEQUENCE,
     MP_F_UNPACK_EX,
     MP_F_NUMBER_OF,
diff --git a/py/sequence.c b/py/sequence.c
index c940d9f..c73f3ba 100644
--- a/py/sequence.c
+++ b/py/sequence.c
@@ -51,6 +51,8 @@
     }
 }
 
+#if MICROPY_PY_BUILTINS_SLICE
+
 bool mp_seq_get_fast_slice_indexes(machine_uint_t len, mp_obj_t slice, mp_bound_slice_t *indexes) {
     mp_obj_t ostart, ostop, ostep;
     machine_int_t start, stop;
@@ -102,6 +104,8 @@
     return true;
 }
 
+#endif
+
 mp_obj_t mp_seq_extract_slice(uint len, const mp_obj_t *seq, mp_bound_slice_t *indexes) {
     machine_int_t start = indexes->start, stop = indexes->stop;
     machine_int_t step = indexes->step;