© 2026 Hedgehog Software, LLC

TwitterGitHubDiscord
More
CommunitiesDocsAboutTermsPrivacy
Search
Star
Setup for Free
C#C
C#•3y ago•
23 replies
옵자요

How to create a better namespace structure?

I'm new to C#, but I'm having trouble creating a namespace structure

My question is, is it correct for a parent namespace to have a dependency on a child namespace?

https://github.com/dotnet/runtime/tree/main/src/libraries/System.Private.CoreLib/src/System
If I look at the files in the System namespace, they are accessing the sub-namespaces to organise the code, is this an exception because it is the same concept as the root namespace, like a main function, or is it okay to have dependencies on sub-namespaces?
GitHub
runtime/src/libraries/System.Private.CoreLib/src/System at main · d...
.NET is a cross-platform runtime for cloud, mobile, desktop, and IoT apps. - dotnet/runtime
runtime/src/libraries/System.Private.CoreLib/src/System at main · d...
C# banner
C#Join
We are a programming server aimed at coders discussing everything related to C# (CSharp) and .NET.
61,871Members
Resources

Similar Threads

Was this page helpful?
Recent Announcements

Similar Threads

How to create a structure like Discord.NET
C#CC# / help
2y ago
❔ StructureMap.StructureMapException: StructureMap Exception Code: 207
C#CC# / help
3y ago
❔ How to structure DTOs
C#CC# / help
4y ago
How to structure this DTO?
C#CC# / help
4y ago