[libcxx-commits] [PATCH] D151267: mdspan: implement layout_right

Louis Dionne via Phabricator via libcxx-commits libcxx-commits at lists.llvm.org
Tue Jun 27 10:46:35 PDT 2023


ldionne accepted this revision.
ldionne added a comment.

LGTM with nits.



================
Comment at: libcxx/test/std/containers/views/mdspan/layout_right/required_span_size.pass.cpp:12-17
+// constexpr mapping(const extents_type&) noexcept;
+//
+// Preconditions: The size of the multidimensional index space e is representable
+//                as a value of type index_type ([basic.fundamental]).
+//
+// Effects: Direct-non-list-initializes extents_ with e.
----------------
This is wrong.


================
Comment at: libcxx/test/std/containers/views/mdspan/layout_right/required_span_size.pass.cpp:25-33
+template <class E>
+constexpr void test_construction(E e, typename E::index_type expected_size) {
+  using M = std::layout_right::mapping<E>;
+  const M m(e);
+
+  // check required_span_size()
+  ASSERT_NOEXCEPT(m.required_span_size());
----------------



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

https://reviews.llvm.org/D151267



More information about the libcxx-commits mailing list