diff options
author | Paul Sokolovsky <pfalcon@users.sourceforge.net> | 2015-01-01 09:29:28 +0200 |
---|---|---|
committer | Paul Sokolovsky <pfalcon@users.sourceforge.net> | 2015-01-01 22:09:18 +0200 |
commit | 8a8c1fc82f5b1f7e5f7d82970e39d6064f2fd0b4 (patch) | |
tree | cc28a731930175ac9296c7231f41e92bd09535ab /py/builtinimport.c | |
parent | ebde3c694f301a99addf02c3b8ff3834f04663af (diff) |
py: Add basic framework for issuing compile/runtime warnings.
Diffstat (limited to 'py/builtinimport.c')
-rw-r--r-- | py/builtinimport.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/py/builtinimport.c b/py/builtinimport.c index a8f6a8174..fd804ee35 100644 --- a/py/builtinimport.c +++ b/py/builtinimport.c @@ -323,7 +323,7 @@ mp_obj_t mp_builtin___import__(mp_uint_t n_args, const mp_obj_t *args) { vstr_add_str(&path, "__init__.py"); if (mp_import_stat(vstr_str(&path)) != MP_IMPORT_STAT_FILE) { vstr_cut_tail_bytes(&path, sizeof("/__init__.py") - 1); // cut off /__init__.py - printf("Notice: %s is imported as namespace package\n", vstr_str(&path)); + mp_warning("%s is imported as namespace package", vstr_str(&path)); } else { do_load(module_obj, &path); vstr_cut_tail_bytes(&path, sizeof("/__init__.py") - 1); // cut off /__init__.py |