code-analysis
Source code as objects in C# [closed]
Closed. This question is seeking recommendations for books, tools, software libraries, and more. It does not meet Stack Overflow guidelines. It is not currently accepting answers.[详细]
2023-03-23 23:10 分类:问答Resolving code analysis "CA2000" rule in this scenario?
I\'m running a full code analysis on my project, and it says it has 500 issues. I\'ve boiled it down to 300 now, but I\'m struggling with an issue I can\'t seem to find a solution for.[详细]
2023-03-23 21:39 分类:问答This algorithm does not have a quadratic run time right?
I recently had an interview and was given a small problem that I was to code up. The problem was basically find duplicates in an array of length n, using constant space in O(n). Each element is in th[详细]
2023-03-22 13:36 分类:问答.NET Portability Warning: CA1901 PInvoke Declarations Should Be Portable
When I add the following lines into my code [DllImport(\"user32.dll\")] static extern void keybd_event(byte key, byte scan, int flags, int extraInfo);[详细]
2023-03-22 06:57 分类:问答Avoiding code analysis CA2000 warning with chained constructors?
The normal pattern for avoiding the CA2000 warning about non-disposed locals is to use a temp variable that gets disposed if anything goes wrong, like:[详细]
2023-03-21 04:35 分类:问答Javascript code analysis and constants
Given there is no cross browser const in Javascript and most of the work-arounds are more complex than I care for, I am just going to go with the naming convention of THIS_IS_A_CONSTANT.All well and g[详细]
2023-03-21 04:12 分类:问答FindBugs - Redundant Comparison to null
I am having findbugs error for the below code, if( obj instanceof CustomerData ) { CustomerData customerData = (CustomerData)obj;[详细]
2023-03-20 12:18 分类:问答Can you turn off conditional compilation symbols from msbuild.exe command line?
We have CODE_ANALYSIS defined in our C# components so that FxCop analyzes them when we build them on our development boxes. I would like to have FxCop turned off when it runs through our build system.[详细]
2023-03-19 22:39 分类:问答Determining method dependency in an Object Oriented class
Is anyone aware of any methodology to try and determine the method and instance variable dependencies that exact for a single method in an object oriented class? For example, if I have the following c[详细]
2023-03-19 00:02 分类:问答Finding property usage counts with reflection
I have a generated file with around 10,000 public static properties and methods. I suspect that a nontrivial number of them are entirely unused开发者_开发百科, but there are around 50 assemblies and m[详细]
2023-03-17 23:20 分类:问答