aboutsummaryrefslogtreecommitdiff
path: root/py/lexer.h
diff options
context:
space:
mode:
authorDamien George <damien.p.george@gmail.com>2014-01-03 14:03:48 +0000
committerDamien George <damien.p.george@gmail.com>2014-01-03 14:03:48 +0000
commit66028ab6dcd1b2ec9504c3473d817649935a4a1e (patch)
treec441ee4d665b3218e235dec24dd5a66a6fe050ef /py/lexer.h
parentaae7847508e2a9555ad3276c5cd4f42b2e66686c (diff)
Basic implementation of import.
import works for simple cases. Still work to do on finding the right script, and setting globals/locals correctly when running an imported function.
Diffstat (limited to 'py/lexer.h')
-rw-r--r--py/lexer.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/py/lexer.h b/py/lexer.h
index f58a38e92..27244fde9 100644
--- a/py/lexer.h
+++ b/py/lexer.h
@@ -138,3 +138,6 @@ bool mp_lexer_opt_str(mp_lexer_t *lex, const char *str);
*/
bool mp_lexer_show_error(mp_lexer_t *lex, const char *msg);
bool mp_lexer_show_error_pythonic(mp_lexer_t *lex, const char *msg);
+
+// used to import a module; must be implemented for a specific port
+mp_lexer_t *mp_import_open_file(qstr mod_name);