我在我的代码中使用关键字 auto
137 auto i = boost::find(adresses, adress);
在使用以下命令编译时,我收到这些错误
[vickey@tb tests]$ clear;g++ testCoverDownloader.cpp ../CoverDownloader.cpp -I /usr/include/QtGui/ -I /usr/include/QtCore/ -lQtGui -lQtCore -std=c++0x
../CoverDownloader.cpp:137:10: error: ‘i’ does not name a type
../CoverDownloader.cpp:139:8: error: ‘i’ was not declared in this scope
使用 -std=c++0x 应该可以解决问题。怎么了 ?