diff options
author | Damien George <damien.p.george@gmail.com> | 2016-09-27 15:45:42 +1000 |
---|---|---|
committer | Damien George <damien.p.george@gmail.com> | 2016-09-27 15:45:42 +1000 |
commit | 897129a7ff46ee82228369ed8fab43a7c0acb692 (patch) | |
tree | 356feb7f47d9c4eea222d3cd6ec78571e8233259 | |
parent | 290daa15d9111b3ae7390245406ce95bff6598e8 (diff) | |
download | micropython-897129a7ff46ee82228369ed8fab43a7c0acb692.tar.gz micropython-897129a7ff46ee82228369ed8fab43a7c0acb692.zip |
py/objstr: Remove unreachable function used only for terse error msgs.
-rw-r--r-- | py/objstr.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/py/objstr.c b/py/objstr.c index 406ccf290a..f082e95591 100644 --- a/py/objstr.c +++ b/py/objstr.c @@ -881,9 +881,14 @@ STATIC mp_obj_t arg_as_int(mp_obj_t arg) { return arg; } +#if MICROPY_ERROR_REPORTING == MICROPY_ERROR_REPORTING_TERSE STATIC NORETURN void terse_str_format_value_error(void) { mp_raise_ValueError("bad format string"); } +#else +// define to nothing to improve coverage +#define terse_str_format_value_error() +#endif STATIC vstr_t mp_obj_str_format_helper(const char *str, const char *top, int *arg_i, mp_uint_t n_args, const mp_obj_t *args, mp_map_t *kwargs) { vstr_t vstr; |