Skip to content

Commit 13e361a

Browse files
committed
FIX: mark OS_Exit and OS_Crash functions as noreturn
1 parent 0a0757e commit 13e361a

File tree

2 files changed

+6
-4
lines changed

2 files changed

+6
-4
lines changed

src/os/posix/host-lib.c

+3-2
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
** REBOL [R3] Language Interpreter and Run-time Environment
44
**
55
** Copyright 2012 REBOL Technologies
6+
** Copyright 2012-2023 Rebol Open Source Developers
67
** REBOL is a trademark of REBOL Technologies
78
**
89
** 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
369370

370371
/***********************************************************************
371372
**
372-
*/ void OS_Exit(int code)
373+
*/ REB_NORETURN void OS_Exit(int code)
373374
/*
374375
** Called in all cases when REBOL quits
375376
**
@@ -387,7 +388,7 @@ RL_LIB *RL; // Link back to reb-lib from embedded extensions (like for now: host
387388

388389
/***********************************************************************
389390
**
390-
*/ void OS_Crash(const REBYTE *title, const REBYTE *content)
391+
*/ REB_NORETURN void OS_Crash(const REBYTE *title, const REBYTE *content)
391392
/*
392393
** Tell user that REBOL has crashed. This function must use
393394
** the most obvious and reliable method of displaying the

src/os/win32/host-lib.c

+3-2
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
** REBOL [R3] Language Interpreter and Run-time Environment
44
**
55
** Copyright 2012 REBOL Technologies
6+
** Copyright 2012-2023 Rebol Open Source Developers
67
** REBOL is a trademark of REBOL Technologies
78
**
89
** Licensed under the Apache License, Version 2.0 (the "License");
@@ -371,7 +372,7 @@ static void *Task_Ready;
371372

372373
/***********************************************************************
373374
**
374-
*/ void OS_Exit(int code)
375+
*/ REB_NORETURN void OS_Exit(int code)
375376
/*
376377
** Called in all cases when REBOL quits
377378
**
@@ -397,7 +398,7 @@ static void *Task_Ready;
397398

398399
/***********************************************************************
399400
**
400-
*/ void OS_Crash(const REBYTE *title, const REBYTE *content)
401+
*/ REB_NORETURN void OS_Crash(const REBYTE *title, const REBYTE *content)
401402
/*
402403
** Tell user that REBOL has crashed. This function must use
403404
** the most obvious and reliable method of displaying the

0 commit comments

Comments
 (0)