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
{{ message }}
Repository navigation
Investigate using RegisterSyntaxNodeActionWithDuplicateNodeGuard to avoid duplicate diagnostics #170
Some Roslyn versions call syntax node actions more than once for the same node, which gives duplicate diagnostics (dotnet/roslyn#53136, dotnet/roslyn#58561 and dotnet/roslyn#70488). This affects users on those Roslyn versions, and the tests work around it in many places: the GetExpectedResult...() overrides in the test projects, and code fix providers that remove duplicate text changes (IndentationCodeFixProvider, SA1629CodeFixProvider).
AnalyzerExtensions already has RegisterSyntaxNodeActionWithDuplicateNodeGuard, but it is unused and marked [Obsolete]. Investigate whether to use it for the affected registrations, so the duplicates go away and the workarounds can be removed.
Things to look at:
Which registrations are affected, and whether the guard catches all the duplicates.
An overload for multiple syntax kinds, and what to do about the [Obsolete] attribute.
Activity