# \[Pre-RFC\]: Packages as Namespaces

**URL:** <https://internals.rust-lang.org/t/pre-rfc-packages-as-namespaces/8628>\
**Category:** cargo\
**Created:** [October 19, 2018, 11:32pm UTC](https://internals.rust-lang.org/t/pre-rfc-packages-as-namespaces/8628 "2018-10-19T23:32:31Z")\
**Posts on this page:** 1\
**Showing post:** 26

<div class="post-metadata">

**Author:** ![kornel](https://sea2.discourse-cdn.com/flex002/user_avatar/internals.rust-lang.org/kornel/32/2711_2.png) [@kornel](https://internals.rust-lang.org/u/kornel)\
**Post date:** [October 25, 2018, 3:35pm UTC](https://internals.rust-lang.org/t/pre-rfc-packages-as-namespaces/8628/26 "2018-10-25T15:35:06Z")

</div>

An interesting use of namespaces would be to **relax orphan rules**. [This RFC](https://github.com/sgrif/rfcs/blob/sg-re-re-balancing-coherence/text/0000-re-rebalancing-coherence.md) states that nobody can write `diesel-chrono` crate that integrates the two crates that would like to stay independent of each other.

However, if there was `diesel`🚲`chrono` namespaced crate, then it would be known that all the `diesel`🚲`*` crates are from the same author/owner/org, so they would have power to enforce their own orphan rules across their own crates.

This way the `diesel` crate could remain abstract and not depend on `chrono`, and the `diesel`🚲`chrono` could add `chrono` support by being privileged to implement traits that currently only `diesel` can.

---

_[View the full topic](https://internals.rust-lang.org/t/pre-rfc-packages-as-namespaces/8628)._
