mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 03:17:35 +00:00
AK: Add NO_DISCARD macro to allow clang-format friendly class annotations
clang-format seems to barf on these attributes, to make it easier to use these attributes and have clang-format not mangle the following code we can hide them behind a macro so clang-format doesn't have to handle it.
This commit is contained in:
parent
33834090bb
commit
21a5524d01
1 changed files with 5 additions and 0 deletions
|
@ -51,6 +51,11 @@
|
|||
#endif
|
||||
#define FLATTEN [[gnu::flatten]]
|
||||
|
||||
#ifdef NO_DISCARD
|
||||
# undef NO_DISCARD
|
||||
#endif
|
||||
#define NO_DISCARD [[nodiscard]]
|
||||
|
||||
#ifndef __serenity__
|
||||
# define PAGE_SIZE sysconf(_SC_PAGESIZE)
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue