85 c++ compiler-errors g++ std c++11
我正在尝试编译使用g++
和-std=c++11
或c++0x
标志.
但是,我收到此错误
cc1plus: error: unrecognized command line option "-std=c++11"
Run Code Online (Sandbox Code Playgroud)
g ++ --version
g++ (GCC) 4.1.2 20080704 (Red Hat 4.1.2-54)
Copyright (C) 2006 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
Run Code Online (Sandbox Code Playgroud)
ant*_*ijn 100
从您的G ++版本看,您需要更新它.C++ 11仅在G ++ 4.3之后才可用.最新版本是4.7.
在pre-G ++ 4.7版本中,您必须使用-std=c++0x
,对于您可以使用的更新版本-std=c++11
.
归档时间: |
|
查看次数: |
187382 次 |
最近记录: |