[libcxx-commits] [PATCH] D71997: [libcxx] span: Fix incorrect return type of span::subspan
Louis Dionne via Phabricator via libcxx-commits
libcxx-commits at lists.llvm.org
Tue Feb 11 03:06:01 PST 2020
ldionne accepted this revision.
ldionne added a comment.
This revision is now accepted and ready to land.
Thanks for the patch! Good find. I'll commit this with a slight change to the tests. I'll use this formulation of the `static_assert`s instead, which is clearer IMO:
if constexpr (Count != std::dynamic_extent) {
static_assert(S1::extent == Count);
} else if constexpr (Span::extent != std::dynamic_extent) {
static_assert(S1::extent == Span::extent - Offset);
} else {
static_assert(S1::extent == std::dynamic_extent);
}
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D71997/new/
https://reviews.llvm.org/D71997
More information about the libcxx-commits
mailing list