SA0001: An exception occurred while parsing the file: System.MissingMethodException, Method not found: 'Boolean StyleCop.CSharp.Field.get_Static()'.
description
After updating StyleCop from 4.7.16.0 to the current version 4.7.42.0, we get following exception on some classes, one of it is a Unit Test class.
How can we fix it?
Error 1 SA0001: An exception occurred while parsing the file: System.MissingMethodException, Method not found: 'Boolean StyleCop.CSharp.Field.get_Static()'.
at StyleCop.CSharp.NamingRules.CheckFieldPrefix(Field field, Dictionary2 validPrefixes)
at StyleCop.CSharp.NamingRules.ProcessElement(CsElement element, Dictionary2 validPrefixes, Boolean nativeMethods)
at StyleCop.CSharp.NamingRules.ProcessElement(CsElement element, Dictionary2 validPrefixes, Boolean nativeMethods)
at StyleCop.CSharp.NamingRules.ProcessElement(CsElement element, Dictionary2 validPrefixes, Boolean nativeMethods)
at StyleCop.CSharp.NamingRules.ProcessElement(CsElement element, Dictionary2 validPrefixes, Boolean nativeMethods)
at StyleCop.CSharp.NamingRules.AnalyzeDocument(CodeDocument document)
at StyleCop.StyleCopThread.RunAnalyzers(CodeDocument document, SourceParser parser, IEnumerable1 analyzers)
at StyleCop.StyleCopThread.TestAndRunAnalyzers(CodeDocument document, SourceParser parser, IEnumerable`1 analyzers, Int32 passNumber)
at StyleCop.StyleCopThread.ParseAndAnalyzeDocument(SourceCode sourceCode, DocumentAnalysisStatus documentStatus)
at StyleCop.StyleCopThread.DoWork(Object sender).