std::auto_ptr::release(3)

πŸ“¦ version 2024.07.05, in nixpkgs unstable, opensuse-leap 16.0

πŸ’– NAME πŸ’–

Okay so welcome to the std::auto_ptr::release page, bestie β€” and yes, the name is literally std::auto_ptr::release again. We're in the C++ Standard Libary manual, page std::auto_ptr::release(3), and this is the release glow-up. ✨

✨ Synopsis ✨

T* release() throw();  (deprecated in C++11)
                       (removed in C++17)

This is the whole vibe. It releases the held pointer, and after the call *this holds the null pointer. πŸ’…

Heads up: it's deprecated in C++11 and removed in C++17 β€” iconic but legacy, no cap. 😭

πŸŽ€ Parameters πŸŽ€

Literally none. Zero. Nada. No parameters, bestie. 🫢

πŸ¦‹ Return value πŸ¦‹

It returns get(). That's the whole answer β€” get(). 🌟

🌸 See also 🌸

  • reset β€” replaces the managed object (public member function). iykyk πŸ¦‹

Signing off from http://cppreference.com on 2024.06.10, page std::auto_ptr::release(3) β€” mwah, stay slay, and don't forget your throw() πŸ’–

πŸ“¦ where this page comes from