code-analysis

Can't suppress CA1709 in any way

六眼飞鱼酱① 提交于 2020-01-03 00:22:49
问题 I want to suppress CA1709: Identifiers should be cased correctly, on public class IDd . For example i want to use IDd as correct word. But i can't. I tried everything at code analysis dictionary: <?xml version="1.0" encoding="utf-8"?> <Dictionary> <Words> <Unrecognized> <Word></Word> </Unrecognized> <Recognized> <Word>d</Word> <Word>IDd</Word> </Recognized> <Deprecated> <Term PreferredAlternate=""></Term> </Deprecated> <Compound> <Term CompoundAlternate="IDd">IDd</Term> </Compound>

Retrieve a list of all imports in a Haskell project

谁说我不能喝 提交于 2020-01-02 04:30:12
问题 So, my ultimate goal is to evaluate the accuracy of the dependencies in a cabal file, by ensuring that all the entities that the project imports exist in the versions that it claims to work with. A good start would be finding a list of all the imported entities that a single source file uses, optionally with information as to where they come from. I'm willing to ignore the case of class instances for the moment, since detecting their use is not so straightforward. Ideal answer would be a

Disadvantages of using the `-Wextra` flag when compiling in GCC

我怕爱的太早我们不能终老 提交于 2020-01-02 01:56:49
问题 I know that one should always compile with both -Wall and -Wextra as they enable warnings and help us to understand our mistake, if any. I've read that the -Wextra compiler flag is not recommended to use because it is too verbose with a lot of false positives. I was quite surprised on reading this. So I started googling about it but I didn't get any answer as all the search results showed was "what does the -Wextra flag do?". So, my questions are In which all situations does the -Wextra flag

Visual Studio 2012 Express Code Analysis

ぃ、小莉子 提交于 2020-01-01 16:36:11
问题 The Microsoft documentation talks about a limited set of code analysis tools being available for the express edition (e.g. Microsoft Visual Studio Blog ). I am using VS 2012 update 3, and can not see any code analysis options in context menus, or any buttons or menu options. I am pretty sure I ran some code analysis at some point, but that might have been before update 2 was installed. Does anyone know if this option has been removed from more recent express editions, and if not where I can

Error in FxCop Phoenix analysis engine

人走茶凉 提交于 2020-01-01 11:45:20
问题 So I'm trying to run a bunch of rules which are defined in a RuleSet. The RuleSet file is actually generated using Sonarqube - I've selected absolutely all rules in there, including the FxCop, ReSharper and StyleCop rules. I'm kicking off FxCop like this: C:/FxCop/FxCopCmd.exe /file:C:\TestProject\bin\TestProject.dll /ruleset:=C:\TestProject\testproject.ruleset /out:C:\TestProject\fxcop-report.xml /outxsl:none /forceoutput /searchgac /aspnet It starts correctly, but I get the following

Code analysis comes back with suggestion about not using “out” parameters

廉价感情. 提交于 2020-01-01 10:53:03
问题 I ran the VS 2008 code analysis tool against an object I created and received the following suggestion ... Warning 147 CA1021 : Microsoft.Design : Consider a design that does not require that 'returnValue' be an out parameter. I find "out" parameters rather useful and didn't realize that they were considered as a frowned upon design practice. I wanted to know if someone could shed some light on the reason that I received this Warning? If it is bad practice? why? and what would be good

Code analysis comes back with suggestion about not using “out” parameters

冷暖自知 提交于 2020-01-01 10:52:06
问题 I ran the VS 2008 code analysis tool against an object I created and received the following suggestion ... Warning 147 CA1021 : Microsoft.Design : Consider a design that does not require that 'returnValue' be an out parameter. I find "out" parameters rather useful and didn't realize that they were considered as a frowned upon design practice. I wanted to know if someone could shed some light on the reason that I received this Warning? If it is bad practice? why? and what would be good

Code analysis comes back with suggestion about not using “out” parameters

梦想的初衷 提交于 2020-01-01 10:51:58
问题 I ran the VS 2008 code analysis tool against an object I created and received the following suggestion ... Warning 147 CA1021 : Microsoft.Design : Consider a design that does not require that 'returnValue' be an out parameter. I find "out" parameters rather useful and didn't realize that they were considered as a frowned upon design practice. I wanted to know if someone could shed some light on the reason that I received this Warning? If it is bad practice? why? and what would be good

Where can I find static/dynamic code analysis tools for XSLT?

点点圈 提交于 2020-01-01 09:05:49
问题 Are there any static or dynamic code analysis tools that analyze XSLT/XSL code? The resources I have been able to find so far are: 1. Oxygen xml editor 2. http://gandhimukul.tripod.com/xslt/xslquality.html which looks faily basic in its capabilities 回答1: There are quite a few testing tools and verifiers at Tony Graham's XSLT Testing Tools page. If you haven't looked there, it's a fairly comprehensive list. Using Saxon in schema-aware mode will catch many common errors. You've already

Command-line fulltext indexing?

扶醉桌前 提交于 2020-01-01 08:54:08
问题 We have a huge, old, horrible codebase that makes it nearly impossible to find things when you need it. We're working on improving it, sure... but I often find myself doing massive recursive greps to search through the contents of files to find where things are used. Is there a tool I can use to build a fulltext index of text files in a directory and then query that from the command-line? Prefer something that can be run in user-space and doesn't need a daemon. We have many users on our dev