[PATCH] D51262: Implement P0553 and P0556
Marshall Clow via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Sat Aug 25 12:36:23 PDT 2018
mclow.lists created this revision.
mclow.lists added reviewers: EricWF, ldionne.
Herald added a subscriber: christof.
LWG adopted https://wg21.link/P0553 in Rapperswil, and suggested minor changes to https://wg21.link/P0556.
They kind of go together; for example, `ispow2` is easily implemented using `popcount` - and they share a bunch of infastructure.
I don't recommend landing this until P0556 is approved, but when I implemented one, the other was easy.
None of this stuff will be constexpr on Windows, because the underlying primitives are not constexpr on Windows.
Sorry for the large-ish diff, but (like span) it's 85%+ tests.
https://reviews.llvm.org/D51262
Files:
include/bit
test/libcxx/numerics/bit/bitops.count/countl_one.pass.cpp
test/libcxx/numerics/bit/bitops.count/countl_zero.pass.cpp
test/libcxx/numerics/bit/bitops.count/countr_one.pass.cpp
test/libcxx/numerics/bit/bitops.count/countr_zero.pass.cpp
test/libcxx/numerics/bit/bitops.count/popcount.pass.cpp
test/libcxx/numerics/bit/bitops.rot/rotl.pass.cpp
test/libcxx/numerics/bit/bitops.rot/rotr.pass.cpp
test/std/numerics/bit/bit.pow.two/ceil2.fail.cpp
test/std/numerics/bit/bit.pow.two/ceil2.pass.cpp
test/std/numerics/bit/bit.pow.two/floor2.fail.cpp
test/std/numerics/bit/bit.pow.two/floor2.pass.cpp
test/std/numerics/bit/bit.pow.two/ispow2.fail.cpp
test/std/numerics/bit/bit.pow.two/ispow2.pass.cpp
test/std/numerics/bit/bit.pow.two/log2p1.fail.cpp
test/std/numerics/bit/bit.pow.two/log2p1.pass.cpp
test/std/numerics/bit/bitops.count/countl_one.fail.cpp
test/std/numerics/bit/bitops.count/countl_one.pass.cpp
test/std/numerics/bit/bitops.count/countl_zero.fail.cpp
test/std/numerics/bit/bitops.count/countl_zero.pass.cpp
test/std/numerics/bit/bitops.count/countr_one.fail.cpp
test/std/numerics/bit/bitops.count/countr_one.pass.cpp
test/std/numerics/bit/bitops.count/countr_zero.fail.cpp
test/std/numerics/bit/bitops.count/countr_zero.pass.cpp
test/std/numerics/bit/bitops.count/popcount.fail.cpp
test/std/numerics/bit/bitops.count/popcount.pass.cpp
test/std/numerics/bit/bitops.rot/rotl.fail.cpp
test/std/numerics/bit/bitops.rot/rotl.pass.cpp
test/std/numerics/bit/bitops.rot/rotr.fail.cpp
test/std/numerics/bit/bitops.rot/rotr.pass.cpp
test/std/numerics/bit/nothing_to_do.pass.cpp
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D51262.162561.patch
Type: text/x-patch
Size: 107279 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20180825/33b57a2e/attachment-0001.bin>
More information about the cfe-commits
mailing list