22 references to TargetScope
Microsoft.CodeAnalysis.Features (22)
AbstractRemoveUnnecessaryAttributeSuppressionsDiagnosticAnalyzer.cs (1)
83if (!SuppressMessageAttributeState.HasValidScope(namedAttributeArguments, out var targetScope))
SuppressMessageAttributeState.cs (14)
21private static readonly ImmutableDictionary<string, TargetScope> s_targetScopesMap = CreateTargetScopesMap(); 32private static ImmutableDictionary<string, TargetScope> CreateTargetScopesMap() 34var builder = ImmutableDictionary.CreateBuilder<string, TargetScope>(StringComparer.OrdinalIgnoreCase); 37foreach (TargetScope targetScope in Enum.GetValues(typeof(TargetScope))) 40if (targetScope == TargetScope.None) 79public static bool HasValidScope(ImmutableArray<(string name, IOperation value)> namedAttributeArguments, out TargetScope targetScope) 85targetScope = TargetScope.Module; 89targetScope = TargetScope.None; 98TargetScope targetScope, 109if (targetScope == TargetScope.Resource) 120if (targetScope == TargetScope.Module) 125else if (targetScope == TargetScope.NamespaceAndDescendants) 128targetScope = TargetScope.Namespace;
SuppressMessageAttributeState.TargetSymbolResolver.cs (7)
38private readonly TargetScope _scope; 42public TargetSymbolResolver(Compilation compilation, TargetScope scope, string fullyQualifiedName) 129if (_scope != TargetScope.Namespace && PeekNextChar() == '`') 181if (_scope == TargetScope.Member && !isIndexerProperty && parameters != null) 202case TargetScope.Namespace: 206case TargetScope.Type: 210case TargetScope.Member: