-
Notifications
You must be signed in to change notification settings - Fork 2
/
compat.h
45 lines (41 loc) · 1.64 KB
/
compat.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
/*
* Copyright (c) 2021 Vadim Zhukov <[email protected]>
*
* Permission to use, copy, modify, and distribute this software for any
* purpose with or without fee is hereby granted, provided that the above
* copyright notice and this permission notice appear in all copies.
*
* THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
* WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
* MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
* ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
* WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
* ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
* OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
#ifndef OICB_COMPAT_H
#define OICB_COMPAT_H
#ifndef __dead
#define __dead __attribute__((__noreturn__))
#endif
#ifndef SIMPLEQ_HEAD
#define SIMPLEQ_CONCAT STAILQ_CONCAT
#define SIMPLEQ_EMPTY STAILQ_EMPTY
#define SIMPLEQ_ENTRY STAILQ_ENTRY
#define SIMPLEQ_FIRST STAILQ_FIRST
#define SIMPLEQ_FOREACH STAILQ_FOREACH
#define SIMPLEQ_FOREACH_SAFE STAILQ_FOREACH_SAFE
#define SIMPLEQ_HEAD STAILQ_HEAD
#define SIMPLEQ_HEAD_INITIALIZER STAILQ_HEAD_INITIALIZER
#define SIMPLEQ_INIT STAILQ_INIT
#define SIMPLEQ_INSERT STAILQ_INSERT
#define SIMPLEQ_INSERT_AFTER STAILQ_INSERT_AFTER
#define SIMPLEQ_INSERT_HEAD STAILQ_INSERT_HEAD
#define SIMPLEQ_INSERT_TAIL STAILQ_INSERT_TAIL
#define SIMPLEQ_LAST STAILQ_LAST
#define SIMPLEQ_NEXT STAILQ_NEXT
#define SIMPLEQ_REMOVE STAILQ_REMOVE
#define SIMPLEQ_REMOVE_AFTER STAILQ_REMOVE_AFTER
#define SIMPLEQ_REMOVE_HEAD STAILQ_REMOVE_HEAD
#endif
#endif