Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 3 additions & 5 deletions include/beman/inplace_vector/inplace_vector.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -437,13 +437,11 @@ struct inplace_vector_base : private storage::storage_for<T, N> {
const auto sz = std::min(x.size(), y.size());
for (std::size_t i = 0; i < sz; ++i) {
if (x[i] < y[i])
return std::strong_ordering::less;
return std::weak_ordering::less;
if (y[i] < x[i])
return std::strong_ordering::greater;
// [container.opt.reqmts] < must be total ordering relationship
return std::weak_ordering::greater;
}

return x.size() <=> y.size();
return static_cast<std::weak_ordering>(x.size() <=> y.size());
}
}

Expand Down