error: ‘ostream_iterator’ was not declared in this scope

简介:

 编译程序时出现如下错误error: ‘ostream_iterator’ was not declared in this scope

解决方法如下:在头文件中加入iterator这个头文件

#include<iterator>

错误解决

相关文章
【已解决】Error: Element type is invalid: expected a string (for built-in components) or a class/function
Error: Element type is invalid: expected a string (for built-in components) or a class/function
2407 0
【已解决】Error: Element type is invalid: expected a string (for built-in components) or a class/function
|
7月前
|
Linux C++
【C++编译】C++ error:‘syscall’ was not declared in this scope
sys/syscall.h 内部表示,他封装了![[Pasted image 20220818151746.png]] 打开对应的 syscall.h 文件内部依旧没有 syscall()函数的声明。
63 0
|
11月前
|
数据库 OceanBase
RuntimeError: 'PluginContext' object has no attribute 'set_variable'
RuntimeError: 'PluginContext' object has no attribute 'set_variable'
93 2
error: ‘nullptr’ was not declared in this scope
error: ‘nullptr’ was not declared in this scope
197 0
error: implicit declaration of function ‘RAND_egd’ [-Werror=implicit-function-declaration]
error: implicit declaration of function ‘RAND_egd’ [-Werror=implicit-function-declaration]
100 0
error: implicit declaration of function ‘read‘ [-Werror,-Wimplicit-function-declaration]
error: implicit declaration of function ‘read‘ [-Werror,-Wimplicit-function-declaration]
188 0
|
C语言
error: implicit declaration of function ‘VerifyFixClassname‘ is invalid in C99 [-Werror,-Wimplicit-f
error: implicit declaration of function ‘VerifyFixClassname‘ is invalid in C99 [-Werror,-Wimplicit-f
125 0
错误解决办法:‘NULL’ was not declared in this scope
错误解决办法:‘NULL’ was not declared in this scope
237 0