std::mutex::~mutex(3)

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

πŸŽ€ NAME πŸŽ€

okay so bestie, this is std::mutex::~mutex(3), folded in from the C++ Standard Libary manual β€” yes, β€œLibary,” that’s the manual name, no cap πŸ‘€ β€” and the entry is std::mutex::~mutex β€” literally std::mutex::~mutex. It’s the destructor page for std::mutex. πŸ’…

✨ Synopsis ✨

~mutex();

okay so what does it do? Destroys the mutex. That’s the whole vibe. 🫢

🚨 Undefined-behavior warning, bestie: The behavior is undefined if the mutex is owned by any thread or if any thread terminates while holding any ownership of the mutex. This is not a cute oopsie β€” do not play with it. 😭

πŸ¦‹ See also πŸ¦‹

  • C documentation for mtx_destroy β€” the C-side counterpart, go peek if you want the crossover episode 🌈

mwah πŸ’– β€” source: http://cppreference.com; date/version: 2024.06.10; page: std::mutex::~mutex(3). slay and stay safe with your mutexes ✨

πŸ“¦ where this page comes from