diff options
| author | Scott Shawcroft <scott@tannewt.org> | 2019-04-09 11:36:10 -0700 |
|---|---|---|
| committer | Scott Shawcroft <scott@tannewt.org> | 2019-04-09 11:36:10 -0700 |
| commit | 72992070c5137ce44969555828673ba7ccd69f08 (patch) | |
| tree | 6b0540f83aa47efd12ba43c9dafffc656cd0151a /py | |
| parent | ac7822ba4c144634593c2a0e4a98d0bd75c6de5c (diff) | |
Fix boards with no shared busses.
Diffstat (limited to 'py')
| -rw-r--r-- | py/runtime.c | 8 | ||||
| -rw-r--r-- | py/runtime.h | 1 |
2 files changed, 9 insertions, 0 deletions
diff --git a/py/runtime.c b/py/runtime.c index 060748f1b..1e0100337 100644 --- a/py/runtime.c +++ b/py/runtime.c @@ -1590,6 +1590,14 @@ NORETURN void mp_raise_NotImplementedError(const compressed_string_t *msg) { mp_raise_msg(&mp_type_NotImplementedError, msg); } +NORETURN void mp_raise_NotImplementedError_varg(const compressed_string_t *fmt, ...) { + va_list argptr; + va_start(argptr,fmt); + mp_obj_t exception = mp_obj_new_exception_msg_vlist(&mp_type_NotImplementedError, fmt, argptr); + va_end(argptr); + nlr_raise(exception); +} + #if MICROPY_STACK_CHECK || MICROPY_ENABLE_PYSTACK NORETURN void mp_raise_recursion_depth(void) { mp_raise_RuntimeError(translate("maximum recursion depth exceeded")); diff --git a/py/runtime.h b/py/runtime.h index e52d3232e..2577c9dd5 100644 --- a/py/runtime.h +++ b/py/runtime.h @@ -162,6 +162,7 @@ NORETURN void mp_raise_OSError(int errno_); NORETURN void mp_raise_OSError_msg(const compressed_string_t *msg); NORETURN void mp_raise_OSError_msg_varg(const compressed_string_t *fmt, ...); NORETURN void mp_raise_NotImplementedError(const compressed_string_t *msg); +NORETURN void mp_raise_NotImplementedError_varg(const compressed_string_t *fmt, ...); NORETURN void mp_raise_recursion_depth(void); #if MICROPY_BUILTIN_METHOD_CHECK_SELF_ARG |
