mirror of
https://github.com/micropython/micropython.git
synced 2025-12-15 17:30:14 +01:00
py/mpconfig.h: Enable MICROPY_MODULE_GETATTR by default.
To enable lazy loading of submodules (among other things), which is very useful for MicroPython libraries that want to have optional subcomponents. Disabled explicitly on minimal ports.
This commit is contained in:
@@ -43,6 +43,7 @@
|
||||
#define MICROPY_PY_STRUCT (0)
|
||||
#define MICROPY_PY_SYS (0)
|
||||
#define MICROPY_CPYTHON_COMPAT (0)
|
||||
#define MICROPY_MODULE_GETATTR (0)
|
||||
#define MICROPY_LONGINT_IMPL (MICROPY_LONGINT_IMPL_NONE)
|
||||
#define MICROPY_FLOAT_IMPL (MICROPY_FLOAT_IMPL_NONE)
|
||||
#define MICROPY_USE_INTERNAL_PRINTF (0)
|
||||
|
||||
@@ -55,6 +55,7 @@
|
||||
#define MICROPY_PY_SYS (0)
|
||||
#define MICROPY_MODULE_FROZEN_MPY (1)
|
||||
#define MICROPY_CPYTHON_COMPAT (0)
|
||||
#define MICROPY_MODULE_GETATTR (0)
|
||||
#define MICROPY_LONGINT_IMPL (MICROPY_LONGINT_IMPL_NONE)
|
||||
#define MICROPY_FLOAT_IMPL (MICROPY_FLOAT_IMPL_NONE)
|
||||
|
||||
|
||||
@@ -729,7 +729,7 @@ typedef double mp_float_t;
|
||||
|
||||
// Whether to support module-level __getattr__ (see PEP 562)
|
||||
#ifndef MICROPY_MODULE_GETATTR
|
||||
#define MICROPY_MODULE_GETATTR (0)
|
||||
#define MICROPY_MODULE_GETATTR (1)
|
||||
#endif
|
||||
|
||||
// Whether module weak links are supported
|
||||
|
||||
Reference in New Issue
Block a user