dotnet / roslyn-analyzers

MIT License
1.6k stars 468 forks source link

Two analyzers are using the same description. Consider consolidating into one? #5126

Open Youssef1313 opened 3 years ago

Youssef1313 commented 3 years ago

https://github.com/dotnet/roslyn-analyzers/blob/e8cd97afe333a9bb9aa8b30c7bd00b1ef2b43bd7/src/NetAnalyzers/Core/Microsoft.CodeQuality.Analyzers/MicrosoftCodeQualityAnalyzersResources.resx#L1160-L1162

https://github.com/dotnet/roslyn-analyzers/blob/e8cd97afe333a9bb9aa8b30c7bd00b1ef2b43bd7/src/NetAnalyzers/Core/Microsoft.CodeQuality.Analyzers/MicrosoftCodeQualityAnalyzersResources.resx#L1241-L1243

See if both analyzers should be consolidated into one.

Youssef1313 commented 3 years ago

Implementation-wise, it looks like one of the analyzers is purely about "out" and the other is purely about "ref". I think the important part here is to adjust the description.

Evangelink commented 3 years ago

Are you suggesting to merge the 2 analyzers into one or simply to merge/consolidate the 2 descriptions?

Youssef1313 commented 3 years ago

to merge the 2 analyzers into one

@Evangelink Either that, or distinguishing the descriptions.

Evangelink commented 3 years ago

@mavasani Any preference here?

AraHaan commented 2 years ago

I think I prefer the top one for both cases and just use the top (remove the bottom one).