Is there a tool for finding unreferenced functions (dead, obsolete code) in a C# app? [closed]

Gendarme will detect private methods with no upstream callers. It is available cross platform, and the latest version handles “AvoidUncalledPrivateCodeRule”. FxCop will detect public/protected methods with no upstream callers. However, FxCop does not detect all methods without upstream callers, as it is meant to check in the case that your code is part of a … Read more

What static analysis tools are available for C#? [closed]

Code violation detection Tools: FxCop, excellent tool by Microsoft. Check compliance with .NET framework guidelines. Edit October 2010: No longer available as a standalone download. It is now included in the Windows SDK and after installation can be found in Program Files\Microsoft SDKs\Windows\ [v7.1] \Bin\FXCop\FxCopSetup.exe Edit February 2018: This functionality has now been integrated into … Read more

How can I perform static code analysis in PHP? [closed]

Run php in lint mode from the command line to validate syntax without execution: php -l FILENAME Higher-level static analyzers include: php-sat – Requires http://strategoxt.org/ PHP_Depend PHP_CodeSniffer PHP Mess Detector PHPStan PHP-CS-Fixer phan Lower-level analyzers include: PHP_Parser token_get_all (primitive function) Runtime analyzers, which are more useful for some things due to PHP’s dynamic nature, include: … Read more