2 instantiations of AliasAndUsingDirective
Microsoft.CodeAnalysis.CSharp (2)
Binder\Imports.cs (1)
78
expandedAliasesBuilder.Add(name, new
AliasAndUsingDirective
(directive.Alias.ToNewSubmission(newSubmission), directive.UsingDirective));
Symbols\Source\SourceNamespaceSymbol.AliasesAndUsings.cs (1)
707
var aliasAndDirective = new
AliasAndUsingDirective
(new AliasSymbolFromSyntax(declaringSymbol, usingDirective), usingDirective);
60 references to AliasAndUsingDirective
Microsoft.CodeAnalysis.CSharp (60)
Binder\Binder_Lookup.cs (5)
373
protected bool IsUsingAlias(ImmutableDictionary<string,
AliasAndUsingDirective
> usingAliases, string name, bool callerIsSemanticModel)
375
AliasAndUsingDirective
node;
398
ImmutableDictionary<string,
AliasAndUsingDirective
> usingAliases,
411
AliasAndUsingDirective
alias;
1917
ImmutableDictionary<string,
AliasAndUsingDirective
> usingAliases,
Binder\Binder_Statements.cs (1)
4080
internal virtual ImmutableArray<
AliasAndUsingDirective
> UsingAliases
Binder\ImportChain.cs (2)
95
ImmutableDictionary<string,
AliasAndUsingDirective
> aliasSymbols = Imports.UsingAliases;
104
var
aliasAndUsingDirective = aliasSymbols[alias];
Binder\Imports.cs (7)
28
ImmutableDictionary<string,
AliasAndUsingDirective
>.Empty,
32
public readonly ImmutableDictionary<string,
AliasAndUsingDirective
> UsingAliases;
37
ImmutableDictionary<string,
AliasAndUsingDirective
> usingAliases,
70
var expandedAliases = ImmutableDictionary<string,
AliasAndUsingDirective
>.Empty;
73
var expandedAliasesBuilder = ImmutableDictionary.CreateBuilder<string,
AliasAndUsingDirective
>();
77
var
directive = pair.Value;
152
ImmutableDictionary<string,
AliasAndUsingDirective
> usingAliases,
Binder\InSubmissionClassBinder.cs (1)
62
internal override ImmutableArray<
AliasAndUsingDirective
> UsingAliases => ((SourceNamespaceSymbol)Compilation.SourceModule.GlobalNamespace).GetUsingAliases(_declarationSyntax, basesBeingResolved: null);
Binder\WithExternAliasesBinder.cs (2)
38
ImmutableDictionary<string,
AliasAndUsingDirective
>.Empty,
56
ImmutableDictionary<string,
AliasAndUsingDirective
>.Empty,
Binder\WithExternAndUsingAliasesBinder.cs (11)
32
internal abstract override ImmutableArray<
AliasAndUsingDirective
> UsingAliases { get; }
34
protected abstract ImmutableDictionary<string,
AliasAndUsingDirective
> GetUsingAliasesMap(ConsList<TypeSymbol>? basesBeingResolved);
103
internal static WithExternAndUsingAliasesBinder Create(ImmutableArray<AliasAndExternAliasDirective> externAliases, ImmutableDictionary<string,
AliasAndUsingDirective
> usingAliases, WithUsingNamespacesAndTypesBinder next)
113
private ImmutableArray<
AliasAndUsingDirective
> _lazyUsingAliases;
114
private ImmutableDictionary<string,
AliasAndUsingDirective
>? _lazyUsingAliasesMap;
138
internal override ImmutableArray<
AliasAndUsingDirective
> UsingAliases
151
protected override ImmutableDictionary<string,
AliasAndUsingDirective
> GetUsingAliasesMap(ConsList<TypeSymbol>? basesBeingResolved)
229
private readonly ImmutableDictionary<string,
AliasAndUsingDirective
> _usingAliases;
231
internal FromSymbols(ImmutableArray<AliasAndExternAliasDirective> externAliases, ImmutableDictionary<string,
AliasAndUsingDirective
> usingAliases, WithUsingNamespacesAndTypesBinder next)
247
internal override ImmutableArray<
AliasAndUsingDirective
> UsingAliases
255
protected override ImmutableDictionary<string,
AliasAndUsingDirective
> GetUsingAliasesMap(ConsList<TypeSymbol>? basesBeingResolved)
Binder\WithUsingNamespacesAndTypesBinder.cs (1)
352
return Imports.Create(ImmutableDictionary<string,
AliasAndUsingDirective
>.Empty, _usings, ImmutableArray<AliasAndExternAliasDirective>.Empty);
Compilation\SyntaxTreeSemanticModel.cs (1)
1934
foreach (
var
alias in usingAliases)
Symbols\Source\SourceNamespaceSymbol.AliasesAndUsings.cs (29)
143
public ImmutableArray<
AliasAndUsingDirective
> GetUsingAliases(CSharpSyntaxNode declarationSyntax, ConsList<TypeSymbol>? basesBeingResolved)
153
return ImmutableArray<
AliasAndUsingDirective
>.Empty;
163
return ImmutableArray<
AliasAndUsingDirective
>.Empty;
174
public ImmutableDictionary<string,
AliasAndUsingDirective
> GetUsingAliasesMap(CSharpSyntaxNode declarationSyntax, ConsList<TypeSymbol>? basesBeingResolved)
195
return ImmutableDictionary<string,
AliasAndUsingDirective
>.Empty;
243
private ImmutableDictionary<string,
AliasAndUsingDirective
> GetGlobalUsingAliasesMap(ConsList<TypeSymbol>? basesBeingResolved)
263
ImmutableDictionary<string,
AliasAndUsingDirective
>? mergedAliases = null;
356
var globalAliasesMap = ImmutableDictionary<string,
AliasAndUsingDirective
>.Empty;
380
UsingAliasesMap = mergedAliases ?? ImmutableDictionary<string,
AliasAndUsingDirective
>.Empty,
510
internal ImmutableArray<
AliasAndUsingDirective
> GetUsingAliases(SourceNamespaceSymbol declaringSymbol, CSharpSyntaxNode declarationSyntax, ConsList<TypeSymbol>? basesBeingResolved)
515
internal ImmutableArray<
AliasAndUsingDirective
> GetGlobalUsingAliases(SourceNamespaceSymbol declaringSymbol, CSharpSyntaxNode declarationSyntax, ConsList<TypeSymbol>? basesBeingResolved)
520
internal ImmutableDictionary<string,
AliasAndUsingDirective
> GetUsingAliasesMap(SourceNamespaceSymbol declaringSymbol, CSharpSyntaxNode declarationSyntax, ConsList<TypeSymbol>? basesBeingResolved)
522
return GetUsingsAndDiagnostics(declaringSymbol, declarationSyntax, basesBeingResolved).UsingAliasesMap ?? ImmutableDictionary<string,
AliasAndUsingDirective
>.Empty;
525
internal ImmutableDictionary<string,
AliasAndUsingDirective
> GetGlobalUsingAliasesMap(SourceNamespaceSymbol declaringSymbol, SyntaxReference declarationSyntax, ConsList<TypeSymbol>? basesBeingResolved)
527
return (_lazyGlobalUsings ?? GetGlobalUsingsAndDiagnostics(declaringSymbol, (CSharpSyntaxNode)declarationSyntax.GetSyntax(), basesBeingResolved)).UsingAliasesMap ?? ImmutableDictionary<string,
AliasAndUsingDirective
>.Empty;
599
Debug.Assert((calculated.UsingAliasesMap ?? ImmutableDictionary<string,
AliasAndUsingDirective
>.Empty).SetEquals(result.UsingAliasesMap ?? ImmutableDictionary<string,
AliasAndUsingDirective
>.Empty));
624
var globalUsingAliasesMap = ImmutableDictionary<string,
AliasAndUsingDirective
>.Empty;
626
var globalUsingAliases = ImmutableArray<
AliasAndUsingDirective
>.Empty;
641
ImmutableDictionary<string,
AliasAndUsingDirective
>.Builder? usingAliasesMap = null;
642
ArrayBuilder<
AliasAndUsingDirective
>? usingAliases = null;
707
var
aliasAndDirective = new AliasAndUsingDirective(new AliasSymbolFromSyntax(declaringSymbol, usingDirective), usingDirective);
711
usingAliases = ArrayBuilder<
AliasAndUsingDirective
>.GetInstance();
1097
UsingAliases = ImmutableArray<
AliasAndUsingDirective
>.Empty,
1103
public ImmutableArray<
AliasAndUsingDirective
> UsingAliases { get; init; }
1104
public ImmutableDictionary<string,
AliasAndUsingDirective
>? UsingAliasesMap { get; init; }
1122
UsingAliasesMap = ImmutableDictionary<string,
AliasAndUsingDirective
>.Empty,
1128
public ImmutableDictionary<string,
AliasAndUsingDirective
>? UsingAliasesMap { get; init; }
1139
Imports.Create(UsingAliasesMap ?? ImmutableDictionary<string,
AliasAndUsingDirective
>.Empty,