From 79474c6b164fb66a8d348bfa57613f9dbf5af4e8 Mon Sep 17 00:00:00 2001 From: Damien George Date: Thu, 28 May 2015 14:22:12 +0000 Subject: py: Remove unnecessary extra handling of padding of nan/inf. C's printf will pad nan/inf differently to CPython. Our implementation originally conformed to C, now it conforms to CPython's way. Tests for this are also added in this patch. --- py/objstr.c | 1 - 1 file changed, 1 deletion(-) (limited to 'py/objstr.c') diff --git a/py/objstr.c b/py/objstr.c index 0246262a5..d11f097fc 100644 --- a/py/objstr.c +++ b/py/objstr.c @@ -1200,7 +1200,6 @@ mp_obj_t mp_obj_str_format(mp_uint_t n_args, const mp_obj_t *args, mp_map_t *kwa type = 'g'; } - flags |= PF_FLAG_PAD_NAN_INF; // '{:06e}'.format(float('-inf')) should give '-00inf' switch (type) { #if MICROPY_PY_BUILTINS_FLOAT case 'e': -- cgit v1.2.3