Skip to content
This repository was archived by the owner on Sep 6, 2023. It is now read-only.

Commit 48feb8a

Browse files
committed
stmhal: Enable str.center(), str.[r]partition() and builtin compile().
Also adds "machine" to the list of modules that the parser can search for constants.
1 parent 57226a2 commit 48feb8a

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

stmhal/mpconfigport.h

+4
Original file line numberDiff line numberDiff line change
@@ -67,10 +67,13 @@
6767
#define MICROPY_USE_INTERNAL_ERRNO (1)
6868
#define MICROPY_PY_FUNCTION_ATTRS (1)
6969
#define MICROPY_PY_BUILTINS_STR_UNICODE (1)
70+
#define MICROPY_PY_BUILTINS_STR_CENTER (1)
71+
#define MICROPY_PY_BUILTINS_STR_PARTITION (1)
7072
#define MICROPY_PY_BUILTINS_STR_SPLITLINES (1)
7173
#define MICROPY_PY_BUILTINS_MEMORYVIEW (1)
7274
#define MICROPY_PY_BUILTINS_FROZENSET (1)
7375
#define MICROPY_PY_BUILTINS_EXECFILE (1)
76+
#define MICROPY_PY_BUILTINS_COMPILE (1)
7477
#define MICROPY_PY_ALL_SPECIAL_METHODS (1)
7578
#define MICROPY_PY_MICROPYTHON_MEM_INFO (1)
7679
#define MICROPY_PY_ARRAY_SLICE_ASSIGN (1)
@@ -177,6 +180,7 @@ extern const struct _mp_obj_module_t mp_module_network;
177180
// extra constants
178181
#define MICROPY_PORT_CONSTANTS \
179182
{ MP_OBJ_NEW_QSTR(MP_QSTR_umachine), (mp_obj_t)&machine_module }, \
183+
{ MP_OBJ_NEW_QSTR(MP_QSTR_machine), (mp_obj_t)&machine_module }, \
180184
{ MP_OBJ_NEW_QSTR(MP_QSTR_pyb), (mp_obj_t)&pyb_module }, \
181185
{ MP_OBJ_NEW_QSTR(MP_QSTR_stm), (mp_obj_t)&stm_module }, \
182186

0 commit comments

Comments
 (0)