我在尝试#include iostream时遇到了一些错误。我知道问题出在iostream上,因为我的项目以前编译过,但在包含iostream之后,我就有了错误。
我正在尝试使用iostream,因为printf似乎不起作用,而我想使用cout。
我正在使用keil uVision5,是的,我的文件被保存为main.cpp,但是我的项目中有c文件,但我认为这无关紧要。
有谁有什么想法吗?
哦,忘了包括错误了:
STM324x9I-EVAL-MB1063\STM324x9I-EVAL-MB1063.axf: Error: L6218E: Undefined symbol __fread_bytes_avail (referred from ios.o).
STM324x9I-EVAL-MB1063\STM324x9I-EVAL-MB1063.axf: Error: L6218E: Undefined symbol mbsinit (referred from ios.o).
STM324x9I-EVAL-MB1063\STM324x9I-EVAL-MB1063.axf: Error: L6218E: Undefined symbol wmemmove (referred from ios.o).它也在说:
error in include chain (__exception.h): non-const lvalue reference to type '__builtin_va_list' cannot bind to a value of unrelated type 'va_list' (aka 'std::__va_list')
error in include chain (ostream): explicit specialization of '_C_is_cout' after instantiation我的主文件非常长。我知道不看就很难说出来,但我只是在寻找一个大致的答案。为什么这些错误会出现在std库文件中?std lib文件中应该没有错误
发布于 2014-07-19 04:24:41
你会试着写
' #include "iostream"'也许你应该试着这样写:
'#include "iostream.h"'不过,我只是猜想
https://stackoverflow.com/questions/24732030
复制相似问题