aboutsummaryrefslogtreecommitdiffhomepage
path: root/include/grpc++/config.h
diff options
context:
space:
mode:
authorGravatar Nicolas "Pixel" Noble <pixel@nobis-crew.org>2015-03-13 22:56:19 +0100
committerGravatar Nicolas "Pixel" Noble <pixel@nobis-crew.org>2015-03-13 23:26:08 +0100
commit764971354c530598c32ca2fc133a5350283eeb57 (patch)
tree6ed435096340d477fe31e48701b2821739c6e32f /include/grpc++/config.h
parenta181d2127acdb6038127c92dfe0bb4cc6e906996 (diff)
Allowing us to import google::protobuf::int64.
If for any reason, our definition of gpr_int64 is different from the definition of google::protobuf::int64, the virtual override would fail, as this needs to be of the precisely exactly the same type. That change allows us to use protobuf's int64 definition.
Diffstat (limited to 'include/grpc++/config.h')
-rw-r--r--include/grpc++/config.h12
1 files changed, 9 insertions, 3 deletions
diff --git a/include/grpc++/config.h b/include/grpc++/config.h
index fd7672784b..0267b85215 100644
--- a/include/grpc++/config.h
+++ b/include/grpc++/config.h
@@ -42,9 +42,9 @@
#define GRPC_OVERRIDE override
#endif
-#ifndef GRPC_CUSTOM_STRING
-#include <string>
-#define GRPC_CUSTOM_STRING std::string
+#ifndef GRPC_CUSTOM_PROTOBUF_INT64
+#include <google/protobuf/stubs/common.h>
+#define GRPC_CUSTOM_PROTOBUF_INT64 ::google::protobuf::int64
#endif
#ifndef GRPC_CUSTOM_MESSAGE
@@ -52,6 +52,11 @@
#define GRPC_CUSTOM_MESSAGE ::google::protobuf::Message
#endif
+#ifndef GRPC_CUSTOM_STRING
+#include <string>
+#define GRPC_CUSTOM_STRING std::string
+#endif
+
#ifndef GRPC_CUSTOM_ZEROCOPYOUTPUTSTREAM
#include <google/protobuf/io/zero_copy_stream.h>
#define GRPC_CUSTOM_ZEROCOPYOUTPUTSTREAM ::google::protobuf::io::ZeroCopyOutputStream
@@ -66,6 +71,7 @@ typedef GRPC_CUSTOM_STRING string;
namespace protobuf {
typedef GRPC_CUSTOM_MESSAGE Message;
+typedef GRPC_CUSTOM_PROTOBUF_INT64 int64;
namespace io {
typedef GRPC_CUSTOM_ZEROCOPYOUTPUTSTREAM ZeroCopyOutputStream;