在我的C++代码中,我使用auto
类型来启用C++ 11,我将标志--std=c++0x
添加到我的makefile ,但我仍然得到ISO C++ forbids declaration of .. with no type
错误,如果我启用c + + 11 -std=gnu++11
或-std=c++11
,我得到cc1plus: error: unrecognized command line option "..."
,我的gcc版本是4.3.4
,我应该如何解决这个问题?谢谢。ISO C++禁止声明..没有类型--std = C++ 0x设置
如果不启用C++ 11,我得到了ISO C++ forbids declaration of wallclock with no type
错误的下面一行:
auto wallclock = time(nullptr);
会** **真正有用的,如果你发布运行的代码为我们重现你的错误 – EdChum 2015-03-13 09:12:45
的Makefile是好的,但要了解是什么错误,我们需要看到你的消息来源! – 2015-03-13 09:14:51
@EdChum我加了我的makefile,在我的代码中没有什么特别的,只是一个'auto'类型。 – user4016367 2015-03-13 09:15:07