@@ -6,8 +6,10 @@ namespace StyleCop.Analyzers.DocumentationRules
66 using System ;
77 using System . Collections . Immutable ;
88 using System . Composition ;
9+ using System . Globalization ;
910 using System . Linq ;
1011 using System . Text . RegularExpressions ;
12+ using System . Threading ;
1113 using System . Threading . Tasks ;
1214 using Helpers ;
1315 using Microsoft . CodeAnalysis ;
@@ -79,6 +81,9 @@ private static Task<Document> GetTransformedDocumentAsync(Document document, Syn
7981 var typeDeclaration = node . FirstAncestorOrSelf < BaseTypeDeclarationSyntax > ( ) ;
8082 var declarationSyntax = node . FirstAncestorOrSelf < BaseMethodDeclarationSyntax > ( ) ;
8183 bool isStruct = typeDeclaration . IsKind ( SyntaxKind . StructDeclaration ) ;
84+ var settings = document . Project . AnalyzerOptions . GetStyleCopSettings ( CancellationToken . None ) ;
85+ var culture = new CultureInfo ( settings . DocumentationRules . DocumentationCulture ) ;
86+ var resourceManager = DocumentationResources . ResourceManager ;
8287
8388 TypeParameterListSyntax typeParameterList ;
8489 ClassDeclarationSyntax classDeclaration = typeDeclaration as ClassDeclarationSyntax ;
@@ -122,7 +127,10 @@ private static Task<Document> GetTransformedDocumentAsync(Document document, Syn
122127 }
123128 else if ( declarationSyntax is DestructorDeclarationSyntax )
124129 {
125- standardText = SA1643DestructorSummaryDocumentationMustBeginWithStandardText . DestructorStandardText ;
130+ standardText =
131+ ImmutableArray . Create (
132+ resourceManager . GetString ( "DestructorStandardTextFirstPart" , culture ) ,
133+ resourceManager . GetString ( "DestructorStandardTextSecondPart" , culture ) ) ;
126134 }
127135 else
128136 {
0 commit comments