[libcxx-commits] [PATCH] D81823: adds equality for spaceship types for themselves

Eric Fiselier via Phabricator via libcxx-commits libcxx-commits at lists.llvm.org
Mon Jun 15 12:04:18 PDT 2020

EricWF accepted this revision.
EricWF added inline comments.

Comment at: libcxx/test/std/language.support/cmp/cmp.weakord/weakord.pass.cpp:164
+    static_assert(std::weak_ordering::equivalent != std::weak_ordering::less);
+    static_assert(std::weak_ordering::equivalent ==
cjdb wrote:
> miscco wrote:
> > I am wondering if we really need `B != A` if we already checked `A != B` on the library side.
> > 
> > Can we trust the compiler to have its own valid tests?
> @CaseyCarter mentioned in my `same_as` patch that a lot of the MSVC STL type-traits tests tend to do the testing for the compiler, which is my motivation here. Also, since I expect these names to be ultimately user-defined, I wanted to be 100% sure that they're distinct.
> I have no issues deleting them if you've got strong feelings :)
I like tests. Let's keep them.



More information about the libcxx-commits mailing list