Skip to content

Commit a57746d

Browse files
committed
Fix compiler warnings for noreturn
gc/mmtk/mmtk.c:480:1: warning: function 'rb_mmtk_gc_thread_bug' could be declared with attribute 'noreturn' [-Wmissing-noreturn] 480 | { | ^ gc/mmtk/mmtk.c:510:1: warning: function 'rb_mmtk_mutator_thread_panic_handler' could be declared with attribute 'noreturn' [-Wmissing-noreturn] 510 | { | ^
1 parent f4d8f04 commit a57746d

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

gc/mmtk/mmtk.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -475,6 +475,7 @@ rb_mmtk_special_const_p(MMTk_ObjectReference object)
475475
}
476476

477477
RBIMPL_ATTR_FORMAT(RBIMPL_PRINTF_FORMAT, 1, 2)
478+
RBIMPL_ATTR_NORETURN()
478479
static void
479480
rb_mmtk_gc_thread_bug(const char *msg, ...)
480481
{
@@ -505,6 +506,7 @@ rb_mmtk_gc_thread_panic_handler(void)
505506
rb_mmtk_gc_thread_bug("MMTk GC thread panicked");
506507
}
507508

509+
RBIMPL_ATTR_NORETURN()
508510
static void
509511
rb_mmtk_mutator_thread_panic_handler(void)
510512
{

0 commit comments

Comments
 (0)