std::experi...::operator=(3)
okay so bestie, welcome to the page for std::experi...::operator=(3) β that's the title, and yes we're in the C++ Standard Libary manual. π
This one is about assigning one std::experimental::future to another, and it's giving "move me, don't copy me" energy. β¨
πΈ NAME πΈ
std::experimental::future::operator=βstd::experimental::future::operator=(yes, the NAME section literally does the double-tap, iykyk π«Ά)
π Synopsis π
std::experimental::future<T>& operator=(
std::experimental::future<T>&& other ) (1)
noexcept;
std::experimental::future<T>& operator=( const
std::experimental::future<T>& (2)
other ) = delete;
It assigns the contents of another future object. That's the whole vibe. π¦
- Overload (1) releases any shared state and move-assigns the contents of
otherto*this. After the assignment,other.valid() == falseandthis->valid()will yield the same value asother.valid()before the assignment. No cap. π - Overload (2):
std::experimental::futureis notCopyAssignable. So this one is= delete;, periodt. π
π§ Parameters π§
otherβ astd::experimental::futurethat will transfer state to*this. It's the one handing over the state, main character energy. π
π Return value π
*thisβ that's the return value, literally. π
kisses and sparkles, bestie: this page is from http://cppreference.com and it's dated 2024.06.10. π
π¦ where this page comes from
- nixpkgs unstable: stdman 2024.07.05
- opensuse-leap 16.0: stdman 2024.07.05-bp160.1.9 Β· MIT
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms