{"id":13783713,"url":"https://github.com/Wintellect/Wintellect.Analyzers","last_synced_at":"2025-05-11T19:31:31.299Z","repository":{"id":23303473,"uuid":"26662936","full_name":"Wintellect/Wintellect.Analyzers","owner":"Wintellect","description":".NET Compiler Platform (\"Roslyn\") diagnostic analyzers and code fixes written by Wintellect","archived":false,"fork":false,"pushed_at":"2016-11-25T03:49:58.000Z","size":329,"stargazers_count":90,"open_issues_count":2,"forks_count":11,"subscribers_count":25,"default_branch":"master","last_synced_at":"2024-11-06T00:07:21.879Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"C#","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Wintellect.png","metadata":{"files":{"readme":"ReadMe.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.txt","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2014-11-14T23:57:11.000Z","updated_at":"2024-11-04T14:34:16.000Z","dependencies_parsed_at":"2022-07-07T20:24:46.952Z","dependency_job_id":null,"html_url":"https://github.com/Wintellect/Wintellect.Analyzers","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Wintellect%2FWintellect.Analyzers","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Wintellect%2FWintellect.Analyzers/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Wintellect%2FWintellect.Analyzers/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Wintellect%2FWintellect.Analyzers/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Wintellect","download_url":"https://codeload.github.com/Wintellect/Wintellect.Analyzers/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":224958601,"owners_count":17398497,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-08-03T19:00:29.113Z","updated_at":"2024-11-17T20:31:06.598Z","avatar_url":"https://github.com/Wintellect.png","language":"C#","readme":"# Wintellect.Analyzers #\n\nAt [Wintellect](http://www.wintellect.com), we love anything that will help us write the best code possible. Microsoft's new Roslyn compiler is a huge step in that direction so we had to jump in and start writing analyzers and code fixes we've wanted for years. Feel free to fork and add your own favorites. We'll keep adding these as we think of them.\n\nTo add these analyzers to your project easily, use the NuGet package. In the Visual Studio Package Manager Console exeute the following:\n\n    Install-Package Wintellect.Analyzers\n\n## Design Analyzers ##\n#### [AssembliesHaveCompanyAtrribute](http://code.wintellect.com/Wintellect.Analyzers/WebPages/Wintellect006-AssembliesHaveCompanyAttribute.html) ####\nThis warning ensures you have the AssemblyCompanyAttribute present and a filled out value in the parameter.\n\n#### [AssembliesHaveCopyrightAtrribute](http://code.wintellect.com/Wintellect.Analyzers/WebPages/Wintellect007-AssembliesHaveCopyrightAttribute.html) ####\nThis warning ensures you have the AssemblyCopyrightAttribute present and a filled out value in the parameter.\n\n#### [AssembliesHaveDescriptionAtrribute](http://code.wintellect.com/Wintellect.Analyzers/WebPages/Wintellect008-AssembliesHaveDescriptionAttribute.html) ####\nThis warning ensures you have the AssemblyDescriptionAttribute present and a filled out value in the parameter.\n\n#### [AssembliesHaveTitleAtrribute](http://code.wintellect.com/Wintellect.Analyzers/WebPages/Wintellect009-AssembliesHaveTitleAttribute.html) ####\nThis warning ensures you have the AssemblyTitleAttribute present and a filled out value in the parameter.\n\n#### [CatchBlocksShouldRethrow](http://code.wintellect.com/Wintellect.Analyzers/WebPages/Wintellect014-CatchBlocksShouldRethrow.html) ####\nThis informational analyzer will report when you have a catch block that eats an exception. Because exception handling is so hard\nto get right, this notification is important to remind you too look at those catch blocks.\n\n## Documentation Analyzers ##\n#### [ExceptionDocumentationMissing](http://code.wintellect.com/Wintellect.Analyzers/WebPages/Wintellect010-ExceptionDocumentationMissing.html) ####\nIf you have a direct throw in your code, you need to document it with an \u003cexception\u003e tag in the XML documentation comments. A direct throw is one where you specifically use the throw statement in your code. This analyzer does not apply to private methods, only accessibility levels where calls outside the defining method can take place.\n\n### [SuppressionMessageMissingJustification](http://code.wintellect.com/Wintellect.Analyzers/WebPages/Wintellect011-SuppressMessageMissingJustification.html) ###\nIf you are using the SuppressionMessage attribute to suppress Code Analysis items, you need to fill out the\nJustification property to explicitly state why you are suppressing the report instead of fixing the code.\n\n## Formatting Analyzers ##\n\n#### [IfAndElseMustHaveBraces](http://code.wintellect.com/Wintellect.Analyzers/WebPages/Wintellect003-IfAndElseMustHaveBraces.html) ####\nIf and else statements without braces are reasons for being fired. This analyzer and code fix will help you keep your job. :) The idea for this analyzer was shown by Kevin Pilch-Bisson in his awesome [TechEd talk](http://channel9.msdn.com/Events/TechEd/Europe/2014/DEV-B345). We just finished it off.\n\n## Performance Analyzers ##\n\n#### [AvoidCallingMethodsWithParamArgsInLoops](http://code.wintellect.com/Wintellect.Analyzers/WebPages/Wintellect005-AvoidCallingMethodsWithParamArgInLoops.html) ####\nThis informational level check gives you a hint that you are calling a method using param arrays inside a loop. Because calls to these methods cause memory allocations you should know where these are happening.\n\n## Usage Analzyers ##\n\n#### [AvoidPredefinedTypes](http://code.wintellect.com/Wintellect.Analyzers/WebPages/Wintellect004-AvoidPredefinedTypes.html) ####\nThe predefined types, such as int, should not be used. You want to be as explicit about types as possible to avoid confusion. \n\n#### [CallAssertMethodsWithMessageParameter](http://code.wintellect.com/Wintellect.Analyzers/WebPages/Wintellect002-CallAssertMethodsWithMessageParameters.html) ####\nCalling the one parameter overload of Debug.Assert is a bad idea because they will not show you the expression you are asserting on. This analyzer will find those calls and the code fix will take the asserting expression and convert it into a string as the second parameter to the two parameter overload of Debug.Assert.\n\n#### [ClassesShouldBeSealed](http://code.wintellect.com/Wintellect.Analyzers/WebPages/Wintellect012-ClassesShouldBeSealed.html) #####\nWhen creating new classes, they should be declared with the the sealed modifier.\n\n#### [ReturningTaskRequiresAsync](http://code.wintellect.com/Wintellect.Analyzers/WebPages/Wintellect001-ReturningTaskRequiresAsync.html) ####\nIf you are returning a Task or Task\u003cT\u003e from a method, that method name must end in Async.\n\n#### [UseDebuggerDisplay](http://code.wintellect.com/Wintellect.Analyzers/WebPages/Wintellect013-UseDebuggerDisplayAttribute.html) ####\nAn analyzer and code fix for inserting [DebuggerDisplayAttribute](https://msdn.microsoft.com/en-us/library/system.diagnostics.debuggerdisplayattribute%28v=vs.110%29.aspx) onto public classes. The debugger uses the DebuggerDisplayAttribute to display the class in the expression evaluator (watch/autos/locals windows, data tips) so you can see the important information quickly. The code fix will pull in the first two properties (or fields if one or no properties are present). If the class is derived from IEnumerable, it will default to the count of items. \n \n","funding_links":[],"categories":["Programming Languages","Popular Analyzers"],"sub_categories":["Analyzer collections"],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FWintellect%2FWintellect.Analyzers","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FWintellect%2FWintellect.Analyzers","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FWintellect%2FWintellect.Analyzers/lists"}