summaryrefslogtreecommitdiffstats
path: root/src/util/u_dynarray.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/util/u_dynarray.h')
-rw-r--r--src/util/u_dynarray.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/util/u_dynarray.h b/src/util/u_dynarray.h
index ad3889a7c80..e9109ccd2d1 100644
--- a/src/util/u_dynarray.h
+++ b/src/util/u_dynarray.h
@@ -30,6 +30,10 @@
#include <stdlib.h>
#include "ralloc.h"
+#ifdef __cplusplus
+extern "C" {
+#endif
+
/* A zero-initialized version of this is guaranteed to represent an
* empty array.
*
@@ -134,5 +138,9 @@ util_dynarray_trim(struct util_dynarray *buf)
for (type *elem = (type *)(buf)->data; \
elem < (type *)((char *)(buf)->data + (buf)->size); elem++)
+#ifdef __cplusplus
+}
+#endif
+
#endif /* U_DYNARRAY_H */