py/objslice: Make slice attributes (start/stop/step) readable.
Configurable with MICROPY_PY_BUILTINS_SLICE_ATTRS. Disabled by default.
diff --git a/py/mpconfig.h b/py/mpconfig.h
index eb5b724..57fc227 100644
--- a/py/mpconfig.h
+++ b/py/mpconfig.h
@@ -463,6 +463,12 @@
#define MICROPY_PY_BUILTINS_SLICE (1)
#endif
+// Whether to support slice attribute read access,
+// i.e. slice.start, slice.stop, slice.step
+#ifndef MICROPY_PY_BUILTINS_SLICE_ATTRS
+#define MICROPY_PY_BUILTINS_SLICE_ATTRS (0)
+#endif
+
// Whether to support frozenset object
#ifndef MICROPY_PY_BUILTINS_FROZENSET
#define MICROPY_PY_BUILTINS_FROZENSET (0)