24 class Some :
protected std::shared_ptr<T>
28 Some(
const std::shared_ptr<T>& shared);
29 Some(
const Some<T>& other);
30 Some(Some<T>&& other);
31 Some& operator=(
const Some<T>& other);
45 using std::shared_ptr<T>::get;
49 Some<T>::Some(
const std::shared_ptr<T>& shared)
50 : std::shared_ptr<T>(shared)
54 Some<T>::Some(
const Some<T>& other)
55 : std::shared_ptr<T>(other)
59 Some<T>::Some(Some<T>&& other)
60 : std::shared_ptr<T>(other)
68 Some<T>::operator T*()
75 T* Some<T>::operator->()
91 template <
typename T,
class... Args>
92 Some<T> some(Args&&... args)
94 T* ptr =
new T(args...);
96 return std::shared_ptr<T>(ptr, [](T* p) {
SG_UNREF(p); });