6
голосов
1ответов
4855 просмотров

How to configure StyleCop to suppress warnings on generated code?

Another project, Visual Studio's Code Analysis has this option. But I couldn't find it for StyleCop (AKA Source Analysis). The file I want to ignore is a dbml's .designer.cs code, that includes the // <autogenerated> tag. A blog post tells me that it would be sufficient, but in my case it ...

5
голосов
7ответов
473 просмотров

Is there a way to figure out the top callers of a C function?

Say I have function that is called a LOT from many different places. So I would like to find out who calls this functions the most. For example, top 5 callers or who ever calls this function more than N times. I am using AS3 Linux, gcc 3.4. For now I just put a breakpoint and then stop there ...

8
голосов
2ответов
1953 просмотров

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

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

3
голосов
4ответов
1331 просмотров

How can I compare similar codebases?

We have several C++ projects that were built from the same codebase. There's a lot of similarities and common code between them but they were developed independently; source was not shared in any way. Classes and files will have been renamed even if the underlying code hasn't changed and individu...

2
голосов
1ответов
1491 просмотров

Does anyone use the clang static analyzer for C/objective-C? Is it good or not?

I am aware of a related question where someone mentioned the clang static analyzer but gave no further comments. Most of answers pointed to the lint family which disappointed me from time to time due to the bulk of false positives. I noticed the clang static analyzer when I read XCode release no...

6
голосов
3ответов
5819 просмотров

Ignore code analysis rules in Visual Studio

How do I ignore a specific VS code analysis rule (say CA1305 : Microsoft.Globalization) within a: Method? Class? Namespace? (Assuming these options are all possible.)

6
голосов
3ответов
4643 просмотров

Parsing Classes, Functions and Arguments in PHP

I want to create a function which receives a single argument that holds the path to a PHP file and then parses the given file and returns something like this: class NameOfTheClass function Method1($arg1, $arg2, $arg2) private function Method2($arg1, $arg2, $arg2) public function Method2...

3
голосов
5ответов
3924 просмотров

Looking for a free source code analyzer (Function depedency tree)

Does anybody know where I can find a utility/application running on Windows that analyses C source and outputs a functional dependency tree? What I'm looking for is something along these lines: PrintString->PrintCharacter->PrintByte->Printf

5
голосов
4ответов
1483 просмотров

Code analysis comes back with suggestion about not using "out" parameters

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 t...

1
голосов
2ответов
1030 просмотров

Alternatives to CAT.NET for website security analysis

I'm looking for an alternative tool to CAT.NET for performing static security scans on .NET code. Currently the CAT.NET tooling/development is at a somewhat fragile stage and doesn't offer the reliability that I'm looking for. Are there any alternative static code analyzers that you use for det...

5
голосов
5ответов
3126 просмотров

Tools and best practices to understand somebody else's code

Sometimes one needs to dig into someone else's code, understand it and maybe refactor/fix it. So I'm wondering what tools/practices do you use to do that? It's not about any specific language or platform, rather some advises in general. I myself find it very useful to run the code in question und...

6
голосов
5ответов
945 просмотров

Static code analysis: integrate into debug and release builds, or just one or the other?

As a best practice, do you run code analysis on both debug and release builds, or just one or the other?

15
голосов
4ответов
5296 просмотров

How can I measure source code statistics?

Is there some free tool (preferably command line based) that you can give your root source directory and it will inspect all files and sub-folders and generate a set of nice "statistics"? For example lines of code, number of classes, etc?

2
голосов
5ответов
291 просмотров

Tool for analysing and stepping through code?

Recently I came across a tool which could analyse running python code and produced a visual representation similar to a code editor to allow one to step through the different parts of the code, seeing how many times each part was called, execution time, etc. I can't find the reference to it agai...

1
голосов
2ответов
901 просмотров

Team Foundation Server 2008 Build Server Code Analysis

I'm having trouble getting Code Analysis to run on the build server. My goal is that on checkin the build server will build and run code analysis automatically. For some rules I would like the build to fail. I know how to use the team explorer to set which rules cause a fail. I don't want the...

25
голосов
4ответов
4648 просмотров

How to find (and replace) all old C-style data type casts in my C++ source code?

How can I locate all old C-style cast in my source? I'm using Visual Studio, may be there is some compiler warning that I have to enable?

3
голосов
1ответов
589 просмотров

Why won't the GC automatically dispose my class's members?

When I build the following C++/CLI code in VS2008, a code analysis warning CA1001 is displayed. ref class A { public: A() { m_hwnd = new HWND; } ~A() { this->!A(); } protected: !A() { delete m_hwnd; } HWND* m_hwnd; }; ref class B { public: B() { m_a = gcnew A(); } p...

4
голосов
2ответов
875 просмотров

How can I supress static code analysis during build?

We have a solution with 15 projects, which all has code analysis enabled. The solution easily takes 60+ seconds to build, which is a very long time when sitting waiting. If I disable code analysis it builds in 10 sesonds. I would love to be able to disable code analysis on an ad-hoc basis. But...

1
голосов
3ответов
139 просмотров

Validation that Custom Attibute is assigned to non static class member

I need to create a custom attribute that is applicable only for non static class member. How can I validate this constraint on project compilation or using code analysis tools?

1
голосов
6ответов
1471 просмотров

Extracting the Java method text

I made a tool that measure some cohesion metrics on the Java source files, but these metrics depends that you can determine the list of attributes that are accessed by the method, to do this I made a parser that extract the method code, but I got some problems, so I ask if there any tool to parse...

7
голосов
4ответов
12858 просмотров

Tool for analyzing VB6 source code (like Understand from SciTools)

Does anyone know of a tool to analyze/navigate VB6 source code like the tool from scitools? http://www.scitools.com/products/understand/

21
голосов
6ответов
23374 просмотров

Viewing Code Coverage Results outside of Visual studio

I've got some unit tests, and got some code coverage data. Now, I'd like to be able to view that code coverage data outside of visual studio, say in a web browser. But, when I export the code coverage to an xml file, I can't do anything with it. Are there readers out there for this? Do I have to ...

2
голосов
2ответов
1672 просмотров

Custom Code Analysis TFS Check-In Policy

Is there any way to create a custom TFS check-in policy that can jump through each node within the code being checked in for code standards we have defined?

1
голосов
2ответов
1594 просмотров

Perl Code Security Scanner Other than RATS? (MUST BE _STATIC_)

Other than RATS, are there any other Perl security scanners? Possibly also any STATIC only perl code graph engine which has an ability to follow data-flow or otherwise tainted input?

10
голосов
6ответов
7476 просмотров

Static code analyzers for C

Which static code analyzer (if any) do you use? I've been using PyLint for Python and I'm pretty satisfied with it, now I need something similar for C code. How much of it's output do you have to suppress for normal daily usage?

0
голосов
2ответов
140 просмотров

Visualize compiler warnings

I'm looking for a way to visualize compiler warnings and remarks, by annotating or otherwise showing which lines cause a report. This is much like a modern IDE like NetBeans or Eclipse already does, but I'd like to take output from several compilers (and other static code analysis tools) at onc...

2
голосов
2ответов
541 просмотров

Выход из зоны боли - NDepend

Я как раз запускал один из моих проектов через NDepend, и в отчете моя сборка оказалась прямо в углу зоны боли. Мне просто было интересно, стоит ли мне беспокоиться об этом. Что на самом деле означает «зона боли»? Разве это не означает, что существует много взаимосвязей, и что-то не может изм...

3
голосов
1ответов
444 просмотров

Сериализуемые классы и рефакторинг имен

В моем текущем проекте я использую FxCop для обработки различных предупреждений анализа кода. Что касается правил именования, у меня есть возможность либо изменить имена, чтобы они соответствовали правилам, либо принять решение сохранить текущее написание и отключить предупреждение. Что касается...

0
голосов
3ответов
689 просмотров

Установить анализ кода в Visual Studio 2008 Team System 2008 SP1 без установочного носителя?

Можно ли установить анализ кода в VSTS2008 SP1 без исходного установочного носителя? Есть ли отдельный пакет, который я могу загрузить для его активации? Я установил FxCop 1.36, но это не активирует автоматически вкладки в свойствах проекта. Я проверил, установлен ли анализ кода, перейдя в ра...

3
голосов
3ответов
897 просмотров

Инструмент статического анализа для обнаружения проблем интернационализации

Существуют ли какие-либо инструменты (бесплатные / коммерческие), с помощью которых можно проверить приложение на предмет интернационализации? (или готовность к локализации, если хотите) В первую очередь интересует: Тесты многоязычной реализации Примеры: * [javascript] alert (...