1 instantiation of SectionNameMatcher
Microsoft.CodeAnalysis (1)
CommandLine\AnalyzerConfig.SectionNameMatching.cs (1)
121return new SectionNameMatcher(regex, numberRangePairs.ToImmutableAndFree());
46 references to SectionNameMatcher
Microsoft.CodeAnalysis (8)
CommandLine\AnalyzerConfig.SectionNameMatching.cs (1)
70internal static SectionNameMatcher? TryCreateSectionNameMatcher(string sectionName)
CommandLine\AnalyzerConfigSet.cs (7)
39/// <see cref="SectionNameMatcher"/>s for each section. The entries in the outer array correspond to entries in <see cref="_analyzerConfigs"/>, and each inner array 42private readonly ImmutableArray<ImmutableArray<SectionNameMatcher?>> _analyzerMatchers; 141var allMatchers = ArrayBuilder<ImmutableArray<SectionNameMatcher?>>.GetInstance(_analyzerConfigs.Length); 147var builder = ArrayBuilder<SectionNameMatcher?>.GetInstance(config.NamedSections.Length); 150SectionNameMatcher? matcher = AnalyzerConfig.TryCreateSectionNameMatcher(section.Name); 227ImmutableArray<SectionNameMatcher?> matchers = _analyzerMatchers[analyzerConfigIndex]; 274ImmutableArray<SectionNameMatcher?> matchers = _analyzerMatchers[analyzerConfigIndex];
Microsoft.CodeAnalysis.UnitTests (38)
Analyzers\AnalyzerConfigTests.cs (38)
376SectionNameMatcher matcher = TryCreateSectionNameMatcher("abc").Value; 388SectionNameMatcher matcher = TryCreateSectionNameMatcher("*").Value; 399SectionNameMatcher matcher = TryCreateSectionNameMatcher("*.cs").Value; 416SectionNameMatcher matcher = TryCreateSectionNameMatcher("**.cs").Value; 426SectionNameMatcher matcher = TryCreateSectionNameMatcher("...").Value; 439SectionNameMatcher? matcher = TryCreateSectionNameMatcher("abc\\"); 446SectionNameMatcher matcher = TryCreateSectionNameMatcher("ab?def").Value; 459SectionNameMatcher matcher = TryCreateSectionNameMatcher("ab\\\\c").Value; 470SectionNameMatcher matcher = TryCreateSectionNameMatcher("\\***\\*\\**").Value; 482SectionNameMatcher matcher = TryCreateSectionNameMatcher("\\??\\?*\\??").Value; 496SectionNameMatcher matcher = TryCreateSectionNameMatcher("abc\\{\\}def").Value; 508SectionNameMatcher matcher = TryCreateSectionNameMatcher("abc\\,def").Value; 521SectionNameMatcher matcher = TryCreateSectionNameMatcher("*.{cs,vb,fs}").Value; 542SectionNameMatcher matcher = TryCreateSectionNameMatcher("{*.cs,subdir/test.vb}").Value; 565SectionNameMatcher matcher = TryCreateSectionNameMatcher("{}").Value; 577SectionNameMatcher matcher = TryCreateSectionNameMatcher("{*.cs}").Value; 589SectionNameMatcher? matcher = TryCreateSectionNameMatcher("{{{{}}"); 596SectionNameMatcher? matcher = TryCreateSectionNameMatcher("abc,def"); 603SectionNameMatcher matcher = TryCreateSectionNameMatcher("{test{.cs,.vb},other.{a{bb,cc}}}").Value; 623SectionNameMatcher matcher = TryCreateSectionNameMatcher("ab{-}cd{-,}ef").Value; 637SectionNameMatcher matcher = TryCreateSectionNameMatcher("ab{cs,vb,fs}cd").Value; 660var matcher = TryCreateSectionNameMatcher($"{{{i1}..{i2}}}").Value; 677var matcher = TryCreateSectionNameMatcher($"{{{i1}..{i2}}}").Value; 693var matcher = TryCreateSectionNameMatcher($"{{{i1}..{i2}}}").Value; 711var matcher = TryCreateSectionNameMatcher(matchString).Value; 735var matcher = TryCreateSectionNameMatcher("{0..}").Value; 757var matcher = TryCreateSectionNameMatcher("*.[cf]s").Value; 768var matcher = TryCreateSectionNameMatcher("*.[!cf]s").Value; 781var matcher = TryCreateSectionNameMatcher("*.[^cf]s").Value; 795var matcher = TryCreateSectionNameMatcher("[0-9]x").Value; 808var matcher = TryCreateSectionNameMatcher("[!0-9]x").Value; 821var matcher = TryCreateSectionNameMatcher("[ab0-9]x").Value; 857var matcher = TryCreateSectionNameMatcher(@"[[a]bc").Value; 873var matcher = TryCreateSectionNameMatcher(@"[-ac]bd").Value; 888var matcher = TryCreateSectionNameMatcher(@"[ac-]bd").Value; 903var matcher = TryCreateSectionNameMatcher(@"[ab]]cd").Value; 917var matcher = TryCreateSectionNameMatcher(@"[ab\\]cd").Value; 932var matcher = TryCreateSectionNameMatcher(@"ab\[cd").Value;