Код: Выделить всё
template
concept Swappable = requires(T&& t, U&& u)
{
swap(std::forward(t), std::forward(u));
swap(std::forward(u), std::forward(t));
};
Подробнее здесь: https://stackoverflow.com/questions/797 ... ually-mean
Код: Выделить всё
template
concept Swappable = requires(T&& t, U&& u)
{
swap(std::forward(t), std::forward(u));
swap(std::forward(u), std::forward(t));
};