Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions instructions/csharp.instructions.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ applyTo: '**/*.cs'
- Use pattern matching and switch expressions wherever possible.
- Use `nameof` instead of string literals when referring to member names.
- Ensure that XML doc comments are created for any public APIs. When applicable, include `<example>` and `<code>` documentation in the comments.
- Add a trailing comma after the last value in multi-line arrays, collection initializers, object initializers, and enum declarations to prevent MA0007 warnings.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm unfamiliar with this warning - it does not appear to be part of the Roslyn analyser stack

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah ok. I'll admit to not being familiar with that analayzer stack.

Given that, I think this is a little overly specific for the generate C# instructions, especially as it's only one of the nearly 200 analyzer rules in that nuget package. I would suggest creating a dedicated instructions file that people can optionally layer in if they are using that analyzer too.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

what should be the name of the file of the instruction?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

meziantou-analuzer-rules.instructions.md would probably make sense


## Project Setup and Structure

Expand Down