From 68ad279bf94684d9efebab73f2453d81dbe51c6c Mon Sep 17 00:00:00 2001 From: Jeffrey H Peterson Date: Fri, 17 Feb 2023 19:00:31 -0700 Subject: [PATCH 1/2] Remove [[noreturn]] from 'require' since it should return under most circumstances --- ports-of-call/portable_errors.hpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ports-of-call/portable_errors.hpp b/ports-of-call/portable_errors.hpp index d66d96a5..f5c28413 100644 --- a/ports-of-call/portable_errors.hpp +++ b/ports-of-call/portable_errors.hpp @@ -106,7 +106,7 @@ namespace impl { // Prints an error message describing the failed condition in an // assert (the assertion is applied above in the macro) with file name // and line number. Then aborts. -[[noreturn]] PORTABLE_INLINE_FUNCTION void require(bool condition_bool, +PORTABLE_INLINE_FUNCTION void require(bool condition_bool, const char *const condition, const char *const message, const char *const filename, From 4c0b0f764bd830a143b5eec49978f90212c5553c Mon Sep 17 00:00:00 2001 From: Jeff Peterson Date: Fri, 17 Feb 2023 19:05:51 -0700 Subject: [PATCH 2/2] clang format --- ports-of-call/portable_errors.hpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/ports-of-call/portable_errors.hpp b/ports-of-call/portable_errors.hpp index f5c28413..fa16dd78 100644 --- a/ports-of-call/portable_errors.hpp +++ b/ports-of-call/portable_errors.hpp @@ -107,10 +107,10 @@ namespace impl { // assert (the assertion is applied above in the macro) with file name // and line number. Then aborts. PORTABLE_INLINE_FUNCTION void require(bool condition_bool, - const char *const condition, - const char *const message, - const char *const filename, - int const linenumber) { + const char *const condition, + const char *const message, + const char *const filename, + int const linenumber) { if (!condition_bool) { std::printf( "### ERROR\n Condition: %s\n Message: %s\n File: "