Skip to content

Commit

Permalink
Merge pull request #31 from lanl/jhp/noreturn
Browse files Browse the repository at this point in the history
Remove [[noreturn]] from 'require' since it should return under most circumstances
  • Loading branch information
Yurlungur authored Feb 21, 2023
2 parents e993004 + 4c0b0f7 commit 1b64df8
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions ports-of-call/portable_errors.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -106,11 +106,11 @@ 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,
const char *const condition,
const char *const message,
const char *const filename,
int const linenumber) {
PORTABLE_INLINE_FUNCTION void require(bool condition_bool,
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: "
Expand Down

0 comments on commit 1b64df8

Please sign in to comment.