1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19
#define NULL __null namespace std { template <typename T> struct unique_ptr { T& operator*() const; T* operator->() const; T* get() const; explicit operator bool() const noexcept; }; } struct A { }; void foo() { A& b2 = *std::unique_ptr<A>().get(); }