3 overrides of IsGlobalNamespace
Microsoft.CodeAnalysis.CSharp (3)
Symbols\Metadata\PE\PEGlobalNamespaceSymbol.cs (1)
58public override bool IsGlobalNamespace
Symbols\Metadata\PE\PENestedNamespaceSymbol.cs (1)
102public override bool IsGlobalNamespace
Symbols\Retargeting\RetargetingNamespaceSymbol.cs (1)
185public override bool IsGlobalNamespace
46 references to IsGlobalNamespace
Microsoft.CodeAnalysis.CSharp (46)
Binder\Binder_Lookup.cs (1)
665static bool isRoot(Symbol symbol) => symbol is null || symbol is NamespaceSymbol { IsGlobalNamespace: true };
Binder\Binder_Patterns.cs (1)
953(declContainer.ContainingSymbol as NamespaceSymbol)?.IsGlobalNamespace == true;
Binder\Binder_Symbols.cs (1)
2575if (aliasOpt != null && qualifierOpt.IsNamespace && ((NamespaceSymbol)qualifierOpt).IsGlobalNamespace)
Binder\Imports.cs (3)
123Debug.Assert(!originalNamespace.IsGlobalNamespace, "Global using to global namespace"); 126Debug.Assert(expandedGlobalNamespace.IsGlobalNamespace, "Global namespace required"); 130while (!curr.IsGlobalNamespace)
Binder\Semantics\Conversions\ConversionsBase.cs (1)
3242ContainingNamespace: { Name: "System", ContainingNamespace: { IsGlobalNamespace: true } },
BoundTree\BoundInlineArrayAccess.cs (2)
25ContainingSymbol: NamespaceSymbol { IsGlobalNamespace: true } 55ContainingSymbol: NamespaceSymbol { IsGlobalNamespace: true }
Compiler\DocumentationCommentCompiler.cs (3)
178if (symbol.IsGlobalNamespace) 206if (symbol.IsGlobalNamespace) 1095Debug.Assert(!ns.IsGlobalNamespace);
DocumentationComments\DocumentationCommentIDVisitor.cs (1)
28if (!symbol.IsGlobalNamespace)
Emitter\EditAndContinue\CSharpSymbolMatcher.cs (1)
260Debug.Assert(@namespace.IsGlobalNamespace);
Symbols\AliasSymbol.cs (1)
365RoslynDebug.Assert(target.IsGlobalNamespace);
Symbols\AssemblySymbol.cs (1)
141if (namespaceSymbol.IsGlobalNamespace)
Symbols\Metadata\PE\PENamespaceSymbol.cs (2)
220bool isGlobalNamespace = this.IsGlobalNamespace; 239while (parent?.IsGlobalNamespace == false)
Symbols\ModuleSymbol.cs (1)
383if (namespaceSymbol.IsGlobalNamespace || (object)namespaceSymbol.ContainingNamespace == null)
Symbols\NamedTypeSymbol.cs (1)
1640ContainingNamespace.ContainingNamespace?.IsGlobalNamespace == true &&
Symbols\NamespaceSymbol.cs (2)
132return this.IsGlobalNamespace; 368bool INamespaceSymbolInternal.IsGlobalNamespace => this.IsGlobalNamespace;
Symbols\PublicModel\NamespaceSymbol.cs (1)
27bool INamespaceSymbol.IsGlobalNamespace => _underlying.IsGlobalNamespace;
Symbols\Retargeting\RetargetingNamespaceSymbol.cs (1)
189return _underlyingNamespace.IsGlobalNamespace;
Symbols\Source\SourceAssemblySymbol.cs (1)
1092if (x.Arity != 0 || !x.ContainingNamespace.IsGlobalNamespace || x.Name != "<Module>")
Symbols\Source\SourceMemberContainerSymbol.cs (2)
231Debug.Assert(containingSymbol is NamespaceSymbol { IsGlobalNamespace: true } || !declaration.Declarations.Any(static d => d.IsSimpleProgram)); 3297if (this.ContainingSymbol is not NamespaceSymbol { IsGlobalNamespace: true }
Symbols\Source\SourceMethodSymbolWithAttributes.cs (2)
1112for (var containingNamespace = @this.ContainingNamespace; containingNamespace?.IsGlobalNamespace == false; containingNamespace = containingNamespace.ContainingNamespace) 1325for (var containingNamespace = ContainingNamespace; containingNamespace?.IsGlobalNamespace == false; containingNamespace = containingNamespace.ContainingNamespace)
Symbols\Source\SourceNamespaceSymbol.AliasesAndUsings.cs (5)
257if (!this.IsGlobalNamespace) 918(declaringSymbol.IsGlobalNamespace ? 980Debug.Assert(declaringSymbol.IsGlobalNamespace); 1006Debug.Assert(declaringSymbol.IsGlobalNamespace); 1037Debug.Assert(target.IsGlobalNamespace);
Symbols\Source\SourceNamespaceSymbol.cs (1)
458if (this.IsGlobalNamespace)
Symbols\Source\SourceNamespaceSymbol_Completion.cs (1)
50if (IsGlobalNamespace && (locationOpt is null || targetDeclarationWithImports is object))
Symbols\Synthesized\SynthesizedPrivateImplementationDetailsType.cs (1)
26Debug.Assert(globalNamespace.IsGlobalNamespace);
Symbols\TypeSymbolExtensions.cs (9)
1374ContainingNamespace: { Name: nameof(System), ContainingNamespace.IsGlobalNamespace: true }, 1387ContainingNamespace: { Name: nameof(System), ContainingNamespace.IsGlobalNamespace: true }, 1395ContainingNamespace: { Name: "System", ContainingNamespace: { IsGlobalNamespace: true } }, 1406ContainingNamespace: { Name: "System", ContainingNamespace: { IsGlobalNamespace: true } }, 1417ContainingNamespace: { Name: "System", ContainingNamespace: { IsGlobalNamespace: true } }, 1785if (@namespace.IsGlobalNamespace) 1805if (container.IsGlobalNamespace) 1819else if (!container.IsGlobalNamespace) 2206return globalNamespace != null && globalNamespace.IsGlobalNamespace;