Debian Codegraph @

.cargo/vendor/cbindgen/tests/expectations/cfg_2.cpp

raw
1 #if 0
2 DEF DEFINED = 1
3 DEF NOT_DEFINED = 0
4 #endif
5
6
7 #include <cstdarg>
8 #include <cstdint>
9 #include <cstdlib>
10 #include <ostream>
11 #include <new>
12
13 #if defined(NOT_DEFINED)
14 constexpr static const int32_t DEFAULT_X = 8;
15 #endif
16
17 #if defined(DEFINED)
18 constexpr static const int32_t DEFAULT_X = 42;
19 #endif
20
21 #if (defined(NOT_DEFINED) || defined(DEFINED))
22 struct Foo {
23 int32_t x;
24 };
25 #endif
26
27 #if defined(NOT_DEFINED)
28 struct Bar {
29 Foo y;
30 };
31 #endif
32
33 #if defined(DEFINED)
34 struct Bar {
35 Foo z;
36 };
37 #endif
38
39 struct Root {
40 Bar w;
41 };
42
43 extern "C" {
44
45 void root(Root a);
46
47 } // extern "C"