mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-09-05 09:06:08 +00:00
LibC: The standard C library needs to be able to build as pure C.
Looks like we can't use those comfy C++ attributes in this code then.
This commit is contained in:
parent
3b42db0b4c
commit
cbfd416279
Notes:
sideshowbarker
2024-07-19 15:42:24 +09:00
Author: https://github.com/awesomekling
Commit: cbfd416279
4 changed files with 14 additions and 12 deletions
|
@ -4,7 +4,7 @@
|
|||
|
||||
__BEGIN_DECLS
|
||||
|
||||
[[noreturn]] void __assertion_failed(const char* msg, const char* file, unsigned line, const char* func);
|
||||
__attribute__((noreturn)) void __assertion_failed(const char* msg, const char* file, unsigned line, const char* func);
|
||||
|
||||
#define assert(expr) ((expr) ? (void)0 : __assertion_failed(#expr, __FILE__, __LINE__, __PRETTY_FUNCTION__))
|
||||
#define CRASH() do { asm volatile("ud2"); } while(0)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue