std::swap(s...basic_regex)(3)

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

🌸 NAME 🌸

okay so this page is std::swap(s...basic_regex)(3) from the C++ Standard Libary manual β€” yes bestie, that manual name is literally C++ Standard Libary, and the main character is std::swap(std::basic_regex). Like, the name and the description are both std::swap(std::basic_regex) β€” it's giving β€œI said what I said” energy. πŸ’…βœ¨

✨ Synopsis ✨

here's the signature, no cap:

template< class CharT, class Traits >
void swap( basic_regex<CharT, Traits>& lhs, basic_regex<CharT,
(since C++11)
Traits>& rhs ) noexcept;

and yes, that (since C++11) note is part of the synopsis vibe β€” it's not me adding lore. 🫢

It overloads the std::swap algorithm for std::basic_regex. It exchanges the state of lhs with that of rhs, and effectively calls lhs.swap(rhs). Slay. πŸ”₯

πŸŽ€ Parameters πŸŽ€

  • lhs, rhs β€” regular expressions to swap. That's the whole vibe: two regex besties switching states. 🌈

πŸ’– Return value πŸ’–

(none) β€” literally no return value, bestie. It's a void moment. πŸ’€

πŸ¦‹ Example πŸ¦‹

This section is incomplete Reason: no example

Translation: the example is MIA. Not me opening this section and finding unfinished homework 😭. But hey, at least it's honest.

🌟 See also 🌟

  • swap β€” swaps the contents (public member function). Iconic behavior, same word, member-function energy. πŸ‘‘

🏷️ Category 🏷️

  • * Todo no example

okay bye bestie πŸ’–πŸ«Ά β€” source is http://cppreference.com, date/version is 2024.06.10, and the page is std::swap(s...basic_regex)(3). mwah πŸ’‹βœ¨

πŸ“¦ where this page comes from