除了 FxCop 之外,还有其他方法可以在 .net 中进行代码分析吗?

发布于 2024-12-01 09:14:59 字数 107 浏览 2 评论 0原文

我想知道是否有任何代码分析的替代方法。我想人们可以从头开始创建一个代码分析器,尽管这是一项乏味的工作,而且我不确定它到底是否值得。是否还有其他非 .net 特定的分析器?

谢谢, 太阳

I was wondering if there are any alternatives for code analysis. I suppose one can create a code analyser from scratch though this is a tedious work and I am not sure it worths it after all. Is there other, non .net specific, analysers?

Thanks,
Sun

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(5

听闻余生 2024-12-08 09:14:59

NDepend 是一个商业工具(具有开源/学术版版本),可以为您进行各种分析。尽管它在某些规则上与 FxCop 重叠,但 at 具有更多功能。

我想人们可以从头开始创建一个代码分析器

一切皆有可能,但是编写任何有意义的验证工具都会花费大量时间。如果你的老板付钱给你开发软件,你就会烧他的钱。编写自己的分析器是一个很好的练习,但完全是浪费时间。

NDepend is a commercial tool (with a Open Source / Academic Edition edition) that can do all sorts of analysis for you. Although it overlapps with FxCop for some rules, at has many more features.

I suppose one can create a code analyser from scratch

Everything is possible, but writing any validation tool that has any meaning costs large amounts of time. If your boss pays you for developing software, you will be burning his money. Writing your own analyzer is a good exercise, but will further be a complete waste of time.

你又不是我 2024-12-08 09:14:59

我认为 ReSharper 也有一些代码分析功能,也可以在 SO 中搜索。

顺便说一句,我发现了这个: http://www.itscodingtime.com/post/Visual-Studio-Code-Analysis-vs-FxCop-vs-StyleCope280a6-whats-the-diff.aspx

另请参阅声纳来源:

http://www.sonarsource.org,这是开源的:)

I think ReSharper also has some Code Analysis features, search here in SO as well.

I found this one btw: http://www.itscodingtime.com/post/Visual-Studio-Code-Analysis-vs-FxCop-vs-StyleCope280a6-whats-the-diff.aspx

Also have a look at Sonar Source:

http://www.sonarsource.org, this is open source :)

寻找我们的幸福 2024-12-08 09:14:59

我的公司提供各种用于分析 C# 的工具。

您广泛询问分析工具,因此我假设您不仅仅对静态分析感兴趣。我们还为 C# 提供(基于动态分析的)测试覆盖率和分析器。

My company offers a variety of tools for analyzing C#.

You are asking about analysis tools in a broad way, so I'll assume you are not just interested in static analysis. We also provide (dynamic analysis based) test coverage and profilers for C#.

爱你是孤单的心事 2024-12-08 09:14:59

正如 Davide Piras 所说,您绝对应该看看声纳 C# 插件生态系统。我是该项目的主要贡献者之一,我不属于sonarsource。
这些插件和声纳本身都是开源的。该许可证是 LGPL,因此商业友好。

如果您想查看声纳在 C# 项目上的实际应用,请查看演示实例:

http://nemo.sonarsource.org/dashboard/index/org.mybatis:mybatisdotnet

官方文档可以在这里找到:

http://docs.codehaus.org/display/SONAR/C-Sharp+Plugins +生态系统

如果您需要帮助或对安装过程有任何疑问,请随时订阅用户邮件列表:

http://www.sonarsource.org/support/support/

As said by Davide Piras, you should definitively take a look at sonar C# plugin ecosystem. I am one of the main contributors of the project, I do not belong to sonarsource.
These plugins and sonar itself are open source. The license is LGPL and hence business friendly.

If you want to see sonar in action on C# project, take a look to the demo instance :

http://nemo.sonarsource.org/dashboard/index/org.mybatis:mybatisdotnet

The official documentation is available here :

http://docs.codehaus.org/display/SONAR/C-Sharp+Plugins+Ecosystem

If you need help or have any question regarding the installation process, feel free to subscribe to the user mailing list :

http://www.sonarsource.org/support/support/

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文