You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
With Source Generators becoming more popular now that Roslyn has direct support for it, StyleCop should be able to directly detect and ignore them without each generated file needing to specify // <auto-generated /> in it. That's putting the burden on the source generator author to know about and get right and hurts users of these analyzers who are "caught in the middle."
The text was updated successfully, but these errors were encountered:
StyleCop Analyzers automatically ignores everything that Roslyn says is considered generated code. This should by filed on https://github.com/dotnet/roslyn. I would recommend source generator authors include the // <auto-generated /> comment in the generated code (or name the generated file ending with .g.cs), which is the same requirement that appeared for source generators prior to the ISourceGenerator interface.
With Source Generators becoming more popular now that Roslyn has direct support for it, StyleCop should be able to directly detect and ignore them without each generated file needing to specify
// <auto-generated />
in it. That's putting the burden on the source generator author to know about and get right and hurts users of these analyzers who are "caught in the middle."The text was updated successfully, but these errors were encountered: