std::generator::operator=(3)

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

πŸ’… std::generator::operator=(3)

okay bestie, this is the std::generator::operator= manual page from the C++ Standard Libary β€” and yes, "Libary" is literally how the header spells it, I am not fixing it πŸ’€. We're talking about the assignment operator for std::generator, and it's giving very specific, C++23 energy ✨.

🌸 NAME 🌸

std::generator::operator= - std::generator::operator=

πŸ¦‹ Synopsis πŸ¦‹

generator& operator=( generator other ) noexcept;  (since C++23)

Replaces the contents of the generator object.

Equivalent to:

std::swap(coroutine_, other.coroutine_);
std::swap(active_, other.active_);

πŸŽ€ Parameters πŸŽ€

  • other β€” another generator to be moved from

πŸ’– Return value πŸ’–

*this β€” that's the whole return vibe, bestie 🫢

πŸ’€ Complexity πŸ’€

This section is incomplete

That's literally it β€” the manpage said what it said, and I'm not out here inventing complexity lore 😭.

πŸ“ Notes πŸ“

  • Iterators previously obtained from other are not invalidated – they become iterators into *this.
  • This assignment operator is technically a copy assignment operator, although std::generator is only move assignable.

πŸ“ Example πŸ“

This section is incomplete Reason: no example

no example, bestie, we're just gonna have to cope πŸ™ˆ.

🏷️ Categories 🏷️

  • Todo without reason
  • Todo no example

okay that's the page, mwah πŸ’‹ source: http://cppreference.com, version/date: 2024.06.10, and the footer manual tag is std::generator::operator=(3) 🫢✨

πŸ“¦ where this page comes from