mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 20:57:35 +00:00
LibJS: Mark test262's __assert_fail as extern "C"
and use
...`__attribute__((__noreturn__))` This is more inline with the definition in glibc's version of the file, and stops clang from complaining about it originally not being declared as `[[no_return]]`.
This commit is contained in:
parent
5bd34f115e
commit
e68a35611b
1 changed files with 1 additions and 1 deletions
|
@ -550,7 +550,7 @@ void __assertion_failed(char const* assertion)
|
|||
handle_failed_assert(assertion);
|
||||
}
|
||||
#else
|
||||
[[noreturn]] void __assert_fail(char const* assertion, char const* file, unsigned int line, char const* function)
|
||||
extern "C" __attribute__((__noreturn__)) void __assert_fail(char const* assertion, char const* file, unsigned int line, char const* function)
|
||||
{
|
||||
auto full_message = String::formatted("{}:{}: {}: Assertion `{}' failed.", file, line, function, assertion);
|
||||
handle_failed_assert(full_message.characters());
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue