bsl::operator<=>

Compare lhs and rhs three-way by their stored pointers.

Synopsis

Declared in <bslstl_sharedptr.h>

template<
    class LHS_TYPE,
    class RHS_TYPE>
std::strong_ordering
operator<=>(
    shared_ptr<LHS_TYPE> const& lhs,
    shared_ptr<RHS_TYPE> const& rhs) noexcept;

Description

Perform a three-way comparison of the specified lhs and the specified rhs pointers by using the comparison operators of LHS_TYPE * and RHS_TYPE *; return the result of that comparison.

Return Value

three-way comparison result of the stored pointers

Parameters

NameDescription
lhsleft-hand side operand
rhsright-hand side operand