Microsoft.CodeAnalysis.FxCopAnalyzers (v2.3.0-beta1)
MarkMembersAsStatic
See attached repro project: RoslynAnalyzers.CA1822.ExpressionBodiedMembers.zip
No CA1822 violation.
A CA1822 violation is raised. The error does not appear in the Error List in Visual Studio 2017, but is reported in the Build Output window and the project build is cancelled with error:
1>...RoslynAnalyzers.CA1822.ExpressionBodiedMembersRoslynAnalyzers.CA1822.ExpressionBodiedMembersApplicationConfiguration.cs(15,23,15,60): error CA1822: Member ApplicationInsightsInstrumentationKey does not access instance data and can be marked as static (Shared in VisualBasic)
Probably caused by the dynamic object reference in the arguments of the invoked member.
Likely fixed in latest bits, validate and close.
Confirmed, this no longer repros.