summaryrefslogtreecommitdiff
path: root/py/compile.c
diff options
context:
space:
mode:
Diffstat (limited to 'py/compile.c')
-rw-r--r--py/compile.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/py/compile.c b/py/compile.c
index a9b34ce5d..ad8cffc9d 100644
--- a/py/compile.c
+++ b/py/compile.c
@@ -3667,7 +3667,7 @@ mp_obj_t mp_compile(mp_parse_tree_t *parse_tree, qstr source_file, bool is_repl)
cm.context->module.globals = mp_globals_get();
mp_compile_to_raw_code(parse_tree, source_file, is_repl, &cm);
// return function that executes the outer module
- return mp_make_function_from_raw_code(cm.rc, cm.context, NULL);
+ return mp_make_function_from_proto_fun(cm.rc, cm.context, NULL);
}
#endif // MICROPY_ENABLE_COMPILER