Debian Codegraph @

src/badthreads.h

raw symbols SCIP
1 #ifndef _BADTHREADS_H_
2 #define _BADTHREADS_H_
3
4 /*
5 * This file contains functions and symbols that are defined in C11 threads.h.
6 * If any of these symbols are used in a file that includes badthreads.h, it
7 * should throw an error at compile time.
8 *
9 * The purpose of this file is to make sure that code does not accidentally
10 * use symbols from threads.h. If this happens, and the system C library has
11 * C11-style thread support, then the resulting object could link to the
12 * system's functions that have the same name, instead of the local functions.
13 */
14
15 #define thrd_t THREADS_H_ERROR
16 #define thrd_create THREADS_H_ERROR
17 #define thrd_equal THREADS_H_ERROR
18 #define thrd_current THREADS_H_ERROR
19 #define thrd_sleep THREADS_H_ERROR
20 #define thrd_yield THREADS_H_ERROR
21 #define thrd_exit THREADS_H_ERROR
22 #define thrd_detach THREADS_H_ERROR
23 #define thrd_join THREADS_H_ERROR
24 #define thrd_success THREADS_H_ERROR
25 #define thrd_timedout THREADS_H_ERROR
26 #define thrd_busy THREADS_H_ERROR
27 #define thrd_nomem THREADS_H_ERROR
28 #define thrd_error THREADS_H_ERROR
29 #define thrd_start_t THREADS_H_ERROR
30 #define mtx_t THREADS_H_ERROR
31 #define mtx_init THREADS_H_ERROR
32 #define mtx_lock THREADS_H_ERROR
33 #define mtx_timedlock THREADS_H_ERROR
34 #define mtx_trylock THREADS_H_ERROR
35 #define mtx_unlock THREADS_H_ERROR
36 #define mtx_destroy THREADS_H_ERROR
37 #define mtx_plain THREADS_H_ERROR
38 #define mtx_recursive THREADS_H_ERROR
39 #define mtx_timed THREADS_H_ERROR
40 #define call_once THREADS_H_ERROR
41 #define cnd_t THREADS_H_ERROR
42 #define cnd_init THREADS_H_ERROR
43 #define cnd_signal THREADS_H_ERROR
44 #define cnd_broadcast THREADS_H_ERROR
45 #define cnd_wait THREADS_H_ERROR
46 #define cnd_timedwait THREADS_H_ERROR
47 #define cnd_destroy THREADS_H_ERROR
48 // #define thread_local THREADS_H_ERROR /* Don't redefine thread_local as it is a keyword in C23 */
49 #define tss_t THREADS_H_ERROR
50 #define TSS_DTOR_ITERATIONS THREADS_H_ERROR
51 #define tss_dtor_t THREADS_H_ERROR
52 #define tss_create THREADS_H_ERROR
53 #define tss_get THREADS_H_ERROR
54 #define tss_set THREADS_H_ERROR
55 #define tss_delete THREADS_H_ERROR
56
57
58 #endif