C++17 标准会包含 "std::byte" 吗?
Will the C++17 standard include "std::byte"?
根据http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2016/p0298r0.pdf:
std::byte
is not an integer and not a character. std::byte
is more expressive and type-safe than char
.
但是,wikipedia.
的 C++17 功能列表中未包含此功能
我的问题:C++17 标准会包括 std::byte
吗?
目前在 C++ 17 工作草案中没有提及 std::byte。
参见:http://open-std.org/JTC1/SC22/WG21/docs/papers/2016/n4618.pdf
更新:
C++ 17 将包含 std::byte
http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2017/#mailing2017-03
根据 Chandler Carruth 在 reddit live C++17 thread 上的说法:
C++17 will have a std::byte
type to use when referring to underlying storage rather than having to use char
or unsigned char
!
虽然它尚未反映在最新的工作草案中,但它似乎已在科纳的全体会议上投票通过。这确实发生在两天前,所以给它时间。
它现在在最新的工作草案中,在 <cstddef>
synopsis.
根据http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2016/p0298r0.pdf:
std::byte
is not an integer and not a character.std::byte
is more expressive and type-safe thanchar
.
但是,wikipedia.
的 C++17 功能列表中未包含此功能我的问题:C++17 标准会包括 std::byte
吗?
目前在 C++ 17 工作草案中没有提及 std::byte。
参见:http://open-std.org/JTC1/SC22/WG21/docs/papers/2016/n4618.pdf
更新: C++ 17 将包含 std::byte
http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2017/#mailing2017-03
根据 Chandler Carruth 在 reddit live C++17 thread 上的说法:
C++17 will have a
std::byte
type to use when referring to underlying storage rather than having to usechar
orunsigned char
!
虽然它尚未反映在最新的工作草案中,但它似乎已在科纳的全体会议上投票通过。这确实发生在两天前,所以给它时间。
它现在在最新的工作草案中,在 <cstddef>
synopsis.