aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/core/lib/support/mpscq.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/core/lib/support/mpscq.h')
-rw-r--r--src/core/lib/support/mpscq.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/core/lib/support/mpscq.h b/src/core/lib/support/mpscq.h
index daa51768f7..ca63a044bb 100644
--- a/src/core/lib/support/mpscq.h
+++ b/src/core/lib/support/mpscq.h
@@ -23,6 +23,10 @@
#include <stdbool.h>
#include <stddef.h>
+#ifdef __cplusplus
+extern "C" {
+#endif
+
// Multiple-producer single-consumer lock free queue, based upon the
// implementation from Dmitry Vyukov here:
// http://www.1024cores.net/home/lock-free-algorithms/queues/intrusive-mpsc-node-based-queue
@@ -50,4 +54,8 @@ gpr_mpscq_node *gpr_mpscq_pop(gpr_mpscq *q);
// Pop a node; sets *empty to true if the queue is empty, or false if it is not
gpr_mpscq_node *gpr_mpscq_pop_and_check_end(gpr_mpscq *q, bool *empty);
+#ifdef __cplusplus
+}
+#endif
+
#endif /* GRPC_CORE_LIB_SUPPORT_MPSCQ_H */