[libcxx-commits] [PATCH] D62454: SFINAE on pair/tuple assignment operators 2729

Louis Dionne via Phabricator via libcxx-commits libcxx-commits at lists.llvm.org
Wed Jun 12 13:46:08 PDT 2019


ldionne requested changes to this revision.
ldionne added inline comments.
This revision now requires changes to proceed.


================
Comment at: test/std/utilities/tuple/tuple.tuple/tuple.assign/copy.pass.cpp:115
+        using P = std::pair <int,               int>;
+        static_assert(!std::is_assignable<T, P>::value, "");
+    }
----------------
I think you'd be testing the same thing if you said `!std::is_assignable<T, P const>::value`, but the intent might be clearer. What do you think?

You could also use `T&` instead to clear up any impression that this matters to the test (I had to think about it).


================
Comment at: test/std/utilities/tuple/tuple.tuple/tuple.assign/move_pair.pass.cpp:40
 
+struct CopyAssignable
+{
----------------
I think it would be clearer to say `NonMoveAssignable` here, since this is really the property we're using.


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D62454/new/

https://reviews.llvm.org/D62454





More information about the libcxx-commits mailing list