If lhs and rhs are not valueless by exception and hold the same alternative i, return get(lhs) <=> get(rhs) . If lhs and rhs are not valueless by exception and hold the aalternatives i and j respectively, return i<=>j. Return strong_ordering::equal if both variants are valueless by exception. Return strong_ordering::less if lhs is valueless by exception. Return strong_ordering::greater if rhs is valueless by exception.
Synopsis
Declared in <bslstl_variant.h>
template<class... t_ALTS>
requires (std::three_way_comparable<t_ALTS> && ...)
constexpr
std::common_comparison_category_t<std::compare_three_way_result_t<t_ALTS>...>
operator<=>(
variant<t_ALTS...> const& lhs,
variant<t_ALTS...> const& rhs);
Created with MrDocs