summaryrefslogtreecommitdiffstatshomepage
path: root/py/mpconfig.h
diff options
context:
space:
mode:
Diffstat (limited to 'py/mpconfig.h')
-rw-r--r--py/mpconfig.h9
1 files changed, 9 insertions, 0 deletions
diff --git a/py/mpconfig.h b/py/mpconfig.h
index 64138a9ea7..76aff4681d 100644
--- a/py/mpconfig.h
+++ b/py/mpconfig.h
@@ -1129,6 +1129,15 @@ typedef double mp_float_t;
#define MICROPY_PY_BUILTINS_BYTEARRAY (MICROPY_CONFIG_ROM_LEVEL_AT_LEAST_CORE_FEATURES)
#endif
+// Whether to support code objects, and how many features they have
+#define MICROPY_PY_BUILTINS_CODE_NONE (0)
+#define MICROPY_PY_BUILTINS_CODE_MINIMUM (1)
+#define MICROPY_PY_BUILTINS_CODE_BASIC (2)
+#define MICROPY_PY_BUILTINS_CODE_FULL (3)
+#ifndef MICROPY_PY_BUILTINS_CODE
+#define MICROPY_PY_BUILTINS_CODE (MICROPY_PY_SYS_SETTRACE ? MICROPY_PY_BUILTINS_CODE_FULL : (MICROPY_PY_BUILTINS_COMPILE ? MICROPY_PY_BUILTINS_CODE_MINIMUM : MICROPY_PY_BUILTINS_CODE_NONE))
+#endif
+
// Whether to support dict.fromkeys() class method
#ifndef MICROPY_PY_BUILTINS_DICT_FROMKEYS
#define MICROPY_PY_BUILTINS_DICT_FROMKEYS (MICROPY_CONFIG_ROM_LEVEL_AT_LEAST_CORE_FEATURES)