Reorganize containers (like `hashmap`, `mutable_map`, etc) into a dedicated `collections` folder
jialunzhang-psu opened this issue · comments
Motivations
- The list of packages in core is getting lengthy.
- After putting different containers into a separate collections folder, it becomes more convenient to share implementation between containers. For example,
hashmap
andhashset
share the same underlying Robin Hood hashing.mutable_set
andmutable_map
can share the red-black tree implementation. Maintaining just one copy of the implementation reduces redundant code and tests.
Concern
- Suppose we have
hashmap
,hashset
androbinhood_hash
, three packages under the collections folder, whilehashmap
andhashset
rely onrobinhood_hash
. How to makerobinhood_hash
invisible to the outside?
A potential PR is #324.