std_thread.h(3cxx)

✨ std_thread.h ✨

okay so bestie, this is the manual page for std_thread.h β€” that's section 3cxx of the manual, if you're keeping track πŸ’…. it's a header file manual, not a command, so no synopsis-with-flags energy here, just vibes and class listings πŸ¦‹


🌸 NAME 🌸

std_thread.h β€” the thread-y header, manual page 3cxx, and yes she is a whole queen πŸ‘‘


πŸŽ€ SYNOPSIS πŸŽ€

πŸ’œ Classes

  • struct std::hash< thread::id > β€” the std::hash specialization for thread::id. so you can hash a thread id, bestie, that's the whole job ✨
  • class std::thread::id β€” the class that is a thread id. no notes. iconic behavior πŸ’…
  • class std::thread β€” the actual std::thread class. the main character of this entire header, lowkey πŸ‘‘

πŸ¦‹ Namespaces

  • namespace std β€” the ISO C++ toplevel namespace. that's std. you already know her, she's everywhere, she's the blueprint 🌈
  • namespace std::this_thread β€” the ISO C++ 2011 namespace for interacting with the current thread. the one you're standing in right now, bestie 🫢

πŸ”₯ Functions

  • thread::id std::this_thread::get_id () noexcept β€” gives you the unique identifier of the current thread. that's the one and only you πŸ’–
  • void std::this_thread::yield () noexcept β€” lets the implementation go schedule a different thread instead. it's giving "okay bestie, you go ahead, I'll wait my turn" πŸ™ˆ

🌟 Detailed Description 🌟

okay so the important thing, and I mean the important thing, bestie:

This is an internal header file, included by other library headers. Do not attempt to use it directly. Instead, include <thread>.

fr fr, do not be out here #include-ing this one directly. it's not for you like that. it's backstage. it's the green room. you want the public entrance, and the public entrance is <thread> πŸ’…βœ¨


🫢 Author 🫢

Generated automatically by Doxygen for libstdc++, straight from the source code. so nobody hand-wrote this one, she was born this way 🧚✨


and that's the whole page, babe πŸ’– this manual is libstdc++, dated std_thread.h(3cxx) β€” no cap, that's the footer, and you read it all the way to the end. slay πŸŒΈπŸŽ€πŸ‘‘