std::permutable(3cxx)

πŸ“¦
version 16-20260322 Β· 4 versions
, in ubuntu resolute, ubuntu stonking

✨ NAME ✨

std::permutable β€” [alg.req.permutable], concept permutable

okay so bestie, we're in the std::permutable(3cxx) page from the libstdc++ manual, and this one is literally just a concept. no cap. it's giving "short and iconic."


🌸 SYNOPSIS 🌸

#include <iterator>

πŸŽ€ Concept definition πŸŽ€

template<typename _Iter>
concept std::permutable =  forward_iterator<_Iter>
      && indirectly_movable_storable<_Iter, _Iter>
      && indirectly_swappable<_Iter, _Iter>

so std::permutable is satisfied when all three of those hold for _Iter, in order:

  • forward_iterator<_Iter> β€” gotta be a forward iterator first, periodt πŸ’…
  • indirectly_movable_storable<_Iter, _Iter> β€” the elements need to be indirectly movable and storable across _Iter and itself
  • indirectly_swappable<_Iter, _Iter> β€” and indirectly swappable across _Iter and itself

all three are chained with &&, so if any one of them isn't vibing, the whole concept does not pass the vibe check. πŸ™ˆ


πŸ’œ Detailed Description πŸ’œ

[alg.req.permutable], concept permutable

that's it, that's the whole description β€” it's a concept from the algorithms requirements section, and the library docs just point you back at the same name. short king energy. πŸ‘‘

heads up: the synopsis above is the source of truth here. every requirement is spelled out character-for-character in that concept definition, so don't be out here guessing at extra behaviour, iykyk.

🫢 Author 🫢

Generated automatically by Doxygen for libstdc++ from the source code.


and that's a wrap, bestie! πŸŽ€ this lil page was brought to you by libstdc++, with the author credit going to Doxygen, which generated it automatically straight from the source code. no human wrote the original, but I wrote this, so you're welcome. slay, stay permutable, and go read the source if you want the lore. πŸ’–βœ¨πŸ¦‹

πŸ“¦ where this page comes from