gpt4 book ai didi

c++ - 仅在 C++ 标准中阐述?

转载 作者:可可西里 更新时间:2023-11-01 18:03:50 25 4
gpt4 key购买 nike

exposition only 在 C++ 标准中究竟意味着什么?这是否意味着标记为exposition only 的私有(private)/ protected 成员必须按标准存在,或者它们只是实现的“建议”,根本不需要?

示例包括:

std::error_code::val_
std::wstring_convert::byte_err_string
std::array::elems
std::move_iterator::current
std::reverse_iterator::current
std::ostream_iterator::delim
// And a lot of others

最佳答案

这意味着它们不是标准所要求的,但它们只是说明类的内部结构可能是什么样的,以了解标准委员会所考虑的实现方式.

这基本上是一种传达意图的方式。

关于c++ - 仅在 C++ 标准中阐述?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/34493104/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com