py: Allow registration of modules at their definition.
During make, makemoduledefs.py parses the current builds c files for MP_REGISTER_MODULE(module_name, obj_module, enabled_define) These are used to generate a header with the required entries for "mp_rom_map_elem_t mp_builtin_module_table[]" in py/objmodule.c
This commit is contained in:
committed by
Damien George
parent
e4ac104b7f
commit
cf22f4793c
@@ -40,4 +40,6 @@ const mp_obj_module_t mp_module_array = {
|
||||
.globals = (mp_obj_dict_t*)&mp_module_array_globals,
|
||||
};
|
||||
|
||||
MP_REGISTER_MODULE(MP_QSTR_array, mp_module_array, MICROPY_PY_ARRAY);
|
||||
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user