我知道 ios_base
有一个流状态声明,例如
ios_base::goodbit
(错误状态)
ios_base::ate
(文件打开模式状态)
还有更多。
我感兴趣的是 ios_base
这些成员函数的定义
它们是简单的类还是类模板?它们是如何实现的?哪一个有父类(如果有的话)?
最佳答案
Are they a simple class or a class template?
它们实际上是嵌套在 std::ios_base
中的 static constexpr
声明类(来自 the reference documentation ):
How are they implemented? Which one is there parent class(if any)?
正如那里提到的,它是特定于编译器实现的。通常这些是没有使用父类的简单值。
关于c++ - 不同流状态的定义(C++),我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/27988870/