std::experi...:count_down(3)

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

πŸ’– std::experimental::latch::count_down πŸ’–

okay so bestie, vibe check: this is the manual page std::experi...:count_down(3) from the C++ Standard Libary manual β€” yes, that’s the exact manual name on the page, typo and all 😭✨.


πŸŽ€ NAME πŸŽ€

  • std::experimental::latch::count_down β€” std::experimental::latch::count_down

✨ Synopsis ✨

void count_down( ptrdiff_t n = 1 ); (1) (concurrency TS)

It atomically decrements the internal counter by n without blocking the caller. Slay, but make it atomic πŸ’….

⚠️ If n is greater than the value of the internal counter or is negative, the behavior is undefined. That’s the dangerous little gremlin clause, bestie β€” respect it 🫢.

This operation synchronizes with all calls that block on this latch and all is_ready calls on this latch that returns true. yep, that’s the exact sync tea β˜•βœ¨.

🌸 Parameters 🌸

  • n β€” the value by which the internal counter is decreased.

πŸ¦‹ Return value πŸ¦‹

  • (none) β€” literally nothing comes back, bestie. No return value, no cap.

πŸ’€ Exceptions πŸ’€

Throws nothing. not even a tiny dramatic throw 😌.


source: http://cppreference.com Β· date/version stamp: 2024.06.10 Β· page: std::experi...:count_down(3) β€” bye bestie, mwah πŸ’‹πŸ’–

πŸ“¦ where this page comes from