Skip to content

Account for file scoped namespaces #43146

@KathleenDollard

Description

@KathleenDollard

Type of issue

Outdated article

Description

Very slightly outdated

The using directive can appear:

At the beginning of a source code file, before any namespace or type declarations.
In any block scoped namespace, but before any namespaces or types declared in that namespace, unless the global modifier is used, in which case the directive must appear before all namespace and type declarations.

Page URL

https://learn.microsoft.com/en-us/dotnet/csharp/language-reference/keywords/using-directive

Content source URL

https://github.com/dotnet/docs/blob/main/docs/csharp/language-reference/keywords/using-directive.md

Document Version Independent Id

86a1c11a-1d3c-902b-6cf3-5c004c59a856

Article author

@BillWagner

Metadata

  • ID: 7569e51d-92c7-294a-2d5f-e1ab3c35fdf8
  • Service: dotnet-csharp
  • Sub-service: lang-reference

Associated WorkItem - 330308

Metadata

Metadata

Assignees

Type

No type

Projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions