std::destro...oying_delete(3)

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

πŸ’– NAME πŸ’–

okay so welcome to the std::destro...oying_delete(3) page from the C++ Standard Libary manual β€” yes bestie, that typo is literally in the source, we're leaving it 😭. This one is all about std::destroying_delete_t,std::destroying_delete β€” and yep, the NAME line says it twice: std::destroying_delete_t,std::destroying_delete - std::destroying_delete_t,std::destroying_delete. Both names, same vibe, a whole tag-type situation.

✨ Synopsis ✨

Defined in header <new>:

struct destroying_delete_t { explicit destroying_delete_t() =
(1) (since C++20)
default; };
inline constexpr destroying_delete_t destroying_delete{};
(2) (since C++20)

So (1) is the struct destroying_delete_t glow-up, and (2) is the inline constexpr destroying_delete_t destroying_delete{} variable β€” both marked (since C++20), no cap. It's a tag type used to identify the destroying delete form of operator delete. That's literally its whole job: little nameplate, big "this is the destroying delete version" energy. πŸ’…

🌸 See also 🌸

  • operator delete β€” deallocation functions
  • operator delete[] β€” (function)

mwah πŸ’‹ this came from http://cppreference.com, dated 2024.06.10, and it's the std::destro...oying_delete(3) page β€” bye bestie, go slay some deallocation πŸ«Άβœ¨πŸ¦‹

πŸ“¦ where this page comes from