Rename `urcu_assert()` to `urcu_assert_debug()`
[userspace-rcu.git] / include / urcu / debug.h
1 #ifndef _URCU_DEBUG_H
2 #define _URCU_DEBUG_H
3
4 /*
5 * urcu/debug.h
6 *
7 * Userspace RCU debugging facilities.
8 *
9 * Copyright (c) 2015 Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
10 *
11 * Permission is hereby granted, free of charge, to any person obtaining a copy
12 * of this software and associated documentation files (the "Software"), to deal
13 * in the Software without restriction, including without limitation the rights
14 * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
15 * copies of the Software, and to permit persons to whom the Software is
16 * furnished to do so, subject to the following conditions:
17 *
18 * The above copyright notice and this permission notice shall be included in
19 * all copies or substantial portions of the Software.
20 */
21
22 #include <assert.h>
23
24 #include <urcu/config.h>
25
26 #if defined(DEBUG_RCU) || defined(CONFIG_RCU_DEBUG)
27 # define urcu_assert_debug(...) assert(__VA_ARGS__)
28 #else
29 # define urcu_assert_debug(...)
30 #endif
31
32 /*
33 * For backward compatibility reasons, this file must expose the urcu_assert()
34 * macro.
35 */
36 #define urcu_assert(_cond) urcu_assert_debug(_cond)
37
38 #endif /* _URCU_DEBUG_H */
This page took 0.033936 seconds and 5 git commands to generate.