summaryrefslogtreecommitdiffstatshomepage
path: root/stm/printf.c
diff options
context:
space:
mode:
Diffstat (limited to 'stm/printf.c')
-rw-r--r--stm/printf.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/stm/printf.c b/stm/printf.c
index cfe4204b61..abbc58b669 100644
--- a/stm/printf.c
+++ b/stm/printf.c
@@ -209,6 +209,7 @@ int pfenv_printf(const pfenv_t *pfenv, const char *fmt, va_list args) {
case 'P': // ?
chrs += pfenv_print_int(pfenv, va_arg(args, int), 0, 16, 'A', flags, width);
break;
+#if MICROPY_ENABLE_FLOAT
case 'g':
{
// This is a very hacky approach to printing floats. Micropython
@@ -234,6 +235,7 @@ int pfenv_printf(const pfenv_t *pfenv, const char *fmt, va_list args) {
}
break;
}
+#endif
default:
pfenv->print_strn(pfenv->data, fmt, 1);
chrs += 1;