summaryrefslogtreecommitdiffstatshomepage
path: root/py/mpprint.h
diff options
context:
space:
mode:
Diffstat (limited to 'py/mpprint.h')
-rw-r--r--py/mpprint.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/py/mpprint.h b/py/mpprint.h
index 6e47409ecc..f9204e322d 100644
--- a/py/mpprint.h
+++ b/py/mpprint.h
@@ -39,6 +39,12 @@
#define PF_FLAG_ADD_PERCENT (0x100)
#define PF_FLAG_SHOW_OCTAL_LETTER (0x200)
+#if MICROPY_PY_IO
+# define MP_PYTHON_PRINTER &mp_sys_stdout_print
+#else
+# define MP_PYTHON_PRINTER &mp_plat_print
+#endif
+
typedef void (*mp_print_strn_t)(void *data, const char *str, size_t len);
typedef struct _mp_print_t {