aboutsummaryrefslogtreecommitdiffhomepage
path: root/include/grpc++/config.h
diff options
context:
space:
mode:
authorGravatar vjpai <vpai@google.com>2015-05-21 13:34:00 -0400
committerGravatar Vijay S Pai <vpaiwl@gmail.com>2015-05-21 14:32:10 -0400
commit178a551b5d58fed23db99dd24893c911fb3c1203 (patch)
treed85aa75bc1f9a9726b915ea4f11067d598236d12 /include/grpc++/config.h
parent72b0f3a99e82d58778846278cde2770ffdadc278 (diff)
nullptr->shared_ptr conversion
Diffstat (limited to 'include/grpc++/config.h')
-rw-r--r--include/grpc++/config.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/include/grpc++/config.h b/include/grpc++/config.h
index b6c1705621..55b2a64482 100644
--- a/include/grpc++/config.h
+++ b/include/grpc++/config.h
@@ -112,6 +112,9 @@ public:
template <class T> operator std::unique_ptr<T>() const {
return std::unique_ptr<T>(static_cast<T *>(0));
}
+ template <class T> operator std::shared_ptr<T>() const {
+ return std::shared_ptr<T>(static_cast<T *>(0));
+ }
operator bool() const {return false;}
private:
void operator&() const = delete;