[libcxx-commits] [PATCH] D108250: [libc++] [P1614] Implement std::tuple::operator<=>
Kent Ross via Phabricator via libcxx-commits
libcxx-commits at lists.llvm.org
Fri Aug 20 18:25:44 PDT 2021
mumbleskates marked an inline comment as done.
mumbleskates added inline comments.
================
Comment at: libcxx/test/std/utilities/tuple/tuple.tuple/tuple.rel/three_way_incompatible.fail.cpp:25-26
+{
+ static_cast<void>(std::tuple<int>(1) <=> std::tuple<int, long>(1, 2)); // expected-error {{invalid operands to binary expression}}
+ static_cast<void>(std::tuple<int, long>(1, 2) <=> std::tuple<int>(1)); // expected-error {{invalid operands to binary expression}}
+ return 0;
----------------
cjdb wrote:
> Please change this to a passing compile-time test and use a requires-expression. Similarly in other failure files.
As discussed, this one is a compile-time pass test, and the others are now compile-time tests (but still fail tests, because in operator== and all previous iterations of other relational operators, incompatible sizes are eliminated by static_assert rather than by non-participation so we can't SFINAE or concept our way out of it.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D108250/new/
https://reviews.llvm.org/D108250
More information about the libcxx-commits
mailing list