summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDamien George <damien.p.george@gmail.com>2017-11-29 15:43:40 +1100
committerDamien George <damien.p.george@gmail.com>2017-11-29 15:43:40 +1100
commit3990a52c0f071a7a48cc276f30785930f31eed39 (patch)
treecf50860bed72e2e332cffd2990aef5d970360370
parentb369c1bb9601f83761257d9ba47adef5cbb9ea7b (diff)
py: Annotate func defs with NORETURN when their corresp decls have it.
-rw-r--r--py/objstr.c2
-rw-r--r--py/stackctrl.c2
2 files changed, 2 insertions, 2 deletions
diff --git a/py/objstr.c b/py/objstr.c
index b4f15b38d..30153813d 100644
--- a/py/objstr.c
+++ b/py/objstr.c
@@ -2084,7 +2084,7 @@ bool mp_obj_str_equal(mp_obj_t s1, mp_obj_t s2) {
}
}
-STATIC void bad_implicit_conversion(mp_obj_t self_in) {
+STATIC NORETURN void bad_implicit_conversion(mp_obj_t self_in) {
if (MICROPY_ERROR_REPORTING == MICROPY_ERROR_REPORTING_TERSE) {
mp_raise_TypeError("can't convert to str implicitly");
} else {
diff --git a/py/stackctrl.c b/py/stackctrl.c
index 7cd35fee2..11165b9a6 100644
--- a/py/stackctrl.c
+++ b/py/stackctrl.c
@@ -48,7 +48,7 @@ void mp_stack_set_limit(mp_uint_t limit) {
MP_STATE_THREAD(stack_limit) = limit;
}
-void mp_exc_recursion_depth(void) {
+NORETURN void mp_exc_recursion_depth(void) {
nlr_raise(mp_obj_new_exception_arg1(&mp_type_RuntimeError,
MP_OBJ_NEW_QSTR(MP_QSTR_maximum_space_recursion_space_depth_space_exceeded)));
}