From 0b4ee2ff602b1cc7bc506890e5cdcded53a822d6 Mon Sep 17 00:00:00 2001 From: Tomasz Grabiec Date: Mon, 10 Nov 2014 10:54:21 +0100 Subject: [PATCH] core: advertise element type in shared_ptr<> Other smart pointers also do that. Will help foreign_ptr<>. --- core/shared_ptr.hh | 2 ++ 1 file changed, 2 insertions(+) diff --git a/core/shared_ptr.hh b/core/shared_ptr.hh index f79a655214..30b06dba55 100644 --- a/core/shared_ptr.hh +++ b/core/shared_ptr.hh @@ -43,6 +43,8 @@ private: return shared_ptr(new data(std::forward(a)...)); } public: + using element_type = T; + shared_ptr() = default; shared_ptr(const shared_ptr& x) : _p(x._p) { if (_p) {