code评论立即生成编译器错误 [英] Code comments now generating compiler errors
本文介绍了code评论立即生成编译器错误的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我试图重新编译一个老项目,其中一个同事增添一些更大胆的评论(OK,这些都是Doxygen的意见,我忘了)
I am trying to recompile an older project where a colleague has added few more adventurous comments (ok, these are Doxygen comments, I forgot)
例如三 ///
uint32_t nx; ///< number of columns
这与4.2开发,现在4.8编译器生成以下错误:
It was developed with 4.2 and now with 4.8 the compiler generates the following error:
错误:之前的预期说明符限定符列表'/'标记
error: expected specifier-qualifier-list before ‘/’ token
我应该摆脱所有 ///的
前pressions和替换//
?这是一个大的项目
Should I get rid of all ///
expressions and replace with //
? It's a large project
推荐答案
//
注释不随 -std = C89 $工作C $ C>或
-ansi
选项。使用 -std = C99
或 -std = gnu99
代替。
//
comments do not work with -std=c89
or -ansi
options. Use -std=c99
or -std=gnu99
instead.
这篇关于code评论立即生成编译器错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文