Debian Codegraph @

.cargo/vendor/cbindgen/tests/expectations/constant.both.compat.c

raw
1 #include <stdarg.h>
2 #include <stdbool.h>
3 #include <stdint.h>
4 #include <stdlib.h>
5
6 #define FOO 10
7
8 #define DELIMITER ':'
9
10 #define LEFTCURLY '{'
11
12 #define QUOTE '\''
13
14 #define TAB '\t'
15
16 #define NEWLINE '\n'
17
18 #define HEART U'\U00002764'
19
20 #define EQUID U'\U00010083'
21
22 #define ZOM 3.14
23
24 /**
25 * A single-line doc comment.
26 */
27 #define POS_ONE 1
28
29 /**
30 * A
31 * multi-line
32 * doc
33 * comment.
34 */
35 #define NEG_ONE -1
36
37 #define SHIFT 3
38
39 #define XBOOL 1
40
41 #define XFALSE ((0 << SHIFT) | XBOOL)
42
43 #define XTRUE (1 << (SHIFT | XBOOL))
44
45 #define CAST (uint8_t)'A'
46
47 #define DOUBLE_CAST (uint32_t)(float)1
48
49 typedef struct Foo {
50 int32_t x[FOO];
51 } Foo;
52
53 #ifdef __cplusplus
54 extern "C" {
55 #endif // __cplusplus
56
57 void root(struct Foo x);
58
59 #ifdef __cplusplus
60 } // extern "C"
61 #endif // __cplusplus