summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/c_client.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/c_client.py b/src/c_client.py
index 7a27c1f..ad3ea22 100644
--- a/src/c_client.py
+++ b/src/c_client.py
@@ -175,6 +175,9 @@ def c_open(self):
_c('#include "xcbext.h"')
_c('#include "%s.h"', _ns.header)
+ _c('')
+ _c('#define ALIGNOF(type) offsetof(struct { char dummy; type member; }, member)')
+
if _ns.is_ext:
for (n, h) in self.imports:
_hc('#include "%s.h"', h)
@@ -184,9 +187,6 @@ def c_open(self):
_h('extern "C" {')
_h('#endif')
- _h('')
- _h('#define ALIGNOF(type) offsetof(struct { char dummy; type member; }, member)')
-
if _ns.is_ext:
_h('')
_h('#define XCB_%s_MAJOR_VERSION %s', _ns.ext_name.upper(), _ns.major_version)