TE
科技回声
首页24小时热榜最新最佳问答展示工作
GitHubTwitter
首页

科技回声

基于 Next.js 构建的科技新闻平台,提供全球科技新闻和讨论内容。

GitHubTwitter

首页

首页最新最佳问答展示工作

资源链接

HackerNews API原版 HackerNewsNext.js

© 2025 科技回声. 版权所有。

GCC 4.6 - Support for selectively enabling and disabling warnings via #pragma

24 点作者 lukaszg大约 14 年前

3 条评论

jameskilton大约 14 年前
I'm amazed it took this long but these changes are very VERY welcome:<p>G++ now issues clearer diagnostics for missing semicolons after class, struct, and union definitions.<p>G++ now issues clearer diagnostics for missing semicolons after class member declarations.<p>G++ now issues clearer diagnostics when a colon is used in a place where a double-colon was intended.
评论 #2373025 未加载
scottdw2大约 14 年前
While this is a nice improvement, it still needs work. The biggest problem is that:<p>1. Not all warnings have a -W command line option.<p>2. Sometimes a single -W option will control more than warning message.<p>Contrast this with pretty much every Microsoft Compiler (cl, csc, vbc, fsc, ilasm), where:<p>1. Every error and warning message has a unique number<p>2. The error pragmas and command line options all take numbers as input.<p>3. Errors and warnings are prefixed by their number in compiler output.<p>This makes it easy to know exactly what's being disabled, and what you need to type to disable any warning just by reading the compiler output. Doing that with gcc requires a lot of searching through docs, and usually a bit of trial and error. I wish gcc would adopt the Microsoft model here.
hsmyers大约 14 年前
I'm pleased with the wider availability of quad-precision....means my code can wait a bit longer before switching to very slow 'bignum' style packages.