From 13e361a4a37ba571d7813b66241e6422e496a7a3 Mon Sep 17 00:00:00 2001 From: Oldes Date: Sat, 21 Jan 2023 17:28:46 +0100 Subject: [PATCH] FIX: mark OS_Exit and OS_Crash functions as `noreturn` --- src/os/posix/host-lib.c | 5 +++-- src/os/win32/host-lib.c | 5 +++-- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/src/os/posix/host-lib.c b/src/os/posix/host-lib.c index dab6d32726..e10720872e 100644 --- a/src/os/posix/host-lib.c +++ b/src/os/posix/host-lib.c @@ -3,6 +3,7 @@ ** REBOL [R3] Language Interpreter and Run-time Environment ** ** Copyright 2012 REBOL Technologies +** Copyright 2012-2023 Rebol Open Source Developers ** REBOL is a trademark of REBOL Technologies ** ** Licensed under the Apache License, Version 2.0 (the "License"); @@ -369,7 +370,7 @@ RL_LIB *RL; // Link back to reb-lib from embedded extensions (like for now: host /*********************************************************************** ** -*/ void OS_Exit(int code) +*/ REB_NORETURN void OS_Exit(int code) /* ** Called in all cases when REBOL quits ** @@ -387,7 +388,7 @@ RL_LIB *RL; // Link back to reb-lib from embedded extensions (like for now: host /*********************************************************************** ** -*/ void OS_Crash(const REBYTE *title, const REBYTE *content) +*/ REB_NORETURN void OS_Crash(const REBYTE *title, const REBYTE *content) /* ** Tell user that REBOL has crashed. This function must use ** the most obvious and reliable method of displaying the diff --git a/src/os/win32/host-lib.c b/src/os/win32/host-lib.c index 6ac6b28702..be087ad0fd 100644 --- a/src/os/win32/host-lib.c +++ b/src/os/win32/host-lib.c @@ -3,6 +3,7 @@ ** REBOL [R3] Language Interpreter and Run-time Environment ** ** Copyright 2012 REBOL Technologies +** Copyright 2012-2023 Rebol Open Source Developers ** REBOL is a trademark of REBOL Technologies ** ** Licensed under the Apache License, Version 2.0 (the "License"); @@ -371,7 +372,7 @@ static void *Task_Ready; /*********************************************************************** ** -*/ void OS_Exit(int code) +*/ REB_NORETURN void OS_Exit(int code) /* ** Called in all cases when REBOL quits ** @@ -397,7 +398,7 @@ static void *Task_Ready; /*********************************************************************** ** -*/ void OS_Crash(const REBYTE *title, const REBYTE *content) +*/ REB_NORETURN void OS_Crash(const REBYTE *title, const REBYTE *content) /* ** Tell user that REBOL has crashed. This function must use ** the most obvious and reliable method of displaying the