ostringstream是一个未定义的类型
ostringstream is an undefined type?
在我的C++项目中,我正在尝试这样做:
std::ostringstream stream(std::ostringstream::out);
但我得到了一个错误:
error C2027: use of undefined type 'std::basic_ostringstream<_Elem,_Traits,_Alloc>'
我已经包含了iostream和ostream库,所以我不确定为什么它将ostringstream视为未定义的。。。
std::ostringstream
在<sstream>
中定义。<iostream>
只包含一个正向声明,而<ostream>
根本没有帮助。
相关文章:
- 在VSCode中编译C++给了我一个未定义的参考
- 我对C++程序有一个未定义的参考,不知道如何处理它
- 为什么这是一个未定义的行为?
- 在链接链接静态(GSOAP)库的共享库时,为什么会得到一个未定义的符号
- yaml-cpp:创建一个未定义的节点
- mac构建有一个未定义的符号,而linux构建并没有用于相同的代码
- 为什么我有一个未定义的对友元函数的引用
- 对于自定义类的一个未定义集,是否有一个默认的散列函数
- 在定义之前声明一个未定义的 std::function 的目的是什么?
- 在 c++ 中对 class::function 的另一个未定义的引用
- 有没有办法放入一个未定义大小的数组并作为静态数组继承
- Android NDK:创建一个未定义函数的库
- 为什么我在这个C++代码中得到了一个未定义的引用
- LoopFillZerobss对main有一个未定义的引用
- 为一个未定义的映射打开MP/_gno_parallel
- 休斯顿,我们有一个未定义的参考
- 另一个未定义的引用错误
- g++说我对一个函数有一个未定义的引用
- ostringstream是一个未定义的类型
- 对boost::system::generic的另一个未定义引用