20 General utilities library [utilities]

20.7 Variants [variant]

20.7.10 Specialized algorithms [variant.specalg]

template<class... Types> void swap(variant<Types...>& v, variant<Types...>& w) noexcept(see below);
Constraints: is_­move_­constructible_­v<> && is_­swappable_­v<> is true for all i.
Effects: Equivalent to v.swap(w).
Remarks: The exception specification is equivalent to noexcept(v.swap(w)).