summaryrefslogtreecommitdiff
path: root/eval_intern.h
diff options
context:
space:
mode:
authorNARUSE, Yui <naruse@airemix.jp>2022-01-31 19:22:28 +0900
committerNARUSE, Yui <naruse@airemix.jp>2022-01-31 19:22:28 +0900
commit1c426ddb25e2ccb169720e4f9894605596fe594d (patch)
treee6f37cfbdc442e45eca69e960615ec2e453f35a4 /eval_intern.h
parent629b9da7dbdcaff04d6dde70f2431396f66e03e5 (diff)
merge revision(s) 5c7af72304d0ad33cd3f21b24a4bc44e8acd5b2c,d650b17686d49c2ce8e6a87039861154e93d4621: [Backport #18497]
Assuming EXIT_SUCCESS equals 0 is not portable --- test/ruby/test_fiber.rb | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) `rb_fiber_terminate` must not return [Bug #18497] In a forked process from a fiber, the fiber becomes the only fiber, `fiber_switch` does nothing as there is no other fibers, `rb_fiber_terminate` does not terminate the fiber. In that case, reaches the end of `fiber_entry` finaly, which is declared as "COROUTINE" and should never return. --- cont.c | 3 ++- eval_intern.h | 2 +- test/fiber/test_process.rb | 15 +++++++++++++++ test/ruby/test_fiber.rb | 5 +++++ 4 files changed, 23 insertions(+), 2 deletions(-)
Diffstat (limited to 'eval_intern.h')
-rw-r--r--eval_intern.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/eval_intern.h b/eval_intern.h
index 266a84601e..78feb241a4 100644
--- a/eval_intern.h
+++ b/eval_intern.h
@@ -283,7 +283,7 @@ VALUE rb_make_exception(int argc, const VALUE *argv);
NORETURN(void rb_method_name_error(VALUE, VALUE));
-void rb_fiber_start(rb_fiber_t*);
+NORETURN(void rb_fiber_start(rb_fiber_t*));
NORETURN(void rb_print_undef(VALUE, ID, rb_method_visibility_t));
NORETURN(void rb_print_undef_str(VALUE, VALUE));