1 /*
2  * Copyright (c) 2018-2024, Arm Limited and Contributors. All rights reserved.
3  *
4  * SPDX-License-Identifier: BSD-3-Clause
5  */
6 
7 #ifndef ASSERT_H
8 #define ASSERT_H
9 
10 #include <cdefs.h>
11 
12 #ifndef NDEBUG
13 void __dead2 __assert(const char *file, int line, const char *func, const char *assertion);
14 
15 #define assert(e)	((e) ? (void)0 : __assert(__FILE__, __LINE__, __func__, #e))
16 #else
17 #define assert(e)	((void)(e))
18 #endif
19 
20 #endif /* ASSERT_H */
21