summaryrefslogtreecommitdiffstatshomepage
path: root/py/runtime.c
diff options
context:
space:
mode:
authorDamien George <damien.p.george@gmail.com>2014-01-19 11:48:48 +0000
committerDamien George <damien.p.george@gmail.com>2014-01-19 11:48:48 +0000
commitcbd2f7482c8bf457cc17da763859dbba6e03e2a2 (patch)
tree8d6badc4197fe0d5763d381dd97586176db9fbae /py/runtime.c
parente02b2d43912d13d216936786e4b7a33918877418 (diff)
downloadmicropython-cbd2f7482c8bf457cc17da763859dbba6e03e2a2.tar.gz
micropython-cbd2f7482c8bf457cc17da763859dbba6e03e2a2.zip
py: Add module/function/class name to exceptions.
Exceptions know source file, line and block name. Also tidy up some debug printing functions and provide a global flag to enable/disable them.
Diffstat (limited to 'py/runtime.c')
-rw-r--r--py/runtime.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/py/runtime.c b/py/runtime.c
index fbcc983ab7..e0d76a517a 100644
--- a/py/runtime.c
+++ b/py/runtime.c
@@ -215,9 +215,8 @@ void rt_assign_byte_code(int unique_code_id, byte *code, uint len, int n_args, i
DEBUG_printf(" %02x", code[i]);
}
DEBUG_printf("\n");
-#if MICROPY_SHOW_BC
- extern void mp_show_byte_code(const byte *code, int len);
- mp_show_byte_code(code, len);
+#if MICROPY_DEBUG_PRINTERS
+ mp_byte_code_print(code, len);
#endif
#ifdef WRITE_CODE