Summary
Restructure core libraries
Metadata
- Id: 7749f2ec484f1ecf6ebd98ec93b6ae9602eddb42
- Trac id: 703
- Type: defect
- Reporter: felix
- Owner:
- Cc:
- Status: closed
- Component: core libraries
- Estimated difficulty:
- Resolution: fixed
- Priority: major
- Milestone: 5.0
- Version: 4.7.x
- Changetime: 2018-03-18 22:58:06 UTC
- Created: 2011-09-26 09:05:15 UTC
- Keywords:
Description
The current structure of the libraries is completely arbitrary and both annoyingly impractical and inconsistent. `identity` doesn't belong into `data-structures` and why is `write-line` in `extras` and not in `ports`. The list goes on like this.
The libraries should be restructured fundamentally. To make this backwards-compatible, we could provide wrapper modules (or extensions) that provide the old structure but internally map to the new one. This would also be the opportunity to give more meaningful names to the SRFI libraries (with the `srfi-XXX` identifiers being just aliases).
Changes and comments
[2012-05-21 22:15:38 UTC] alaric wrote:
Names like 'extras' and 'utils' are certainly meaningless. It would be nice and clean if we could just filter them out into suitably-meaningfully-named libraries and just keep the generic names as re-exporting compatibility modules.
Slightly trickier is if we want to move anything out of existing well-named modules such as 'ports', as then we can't have backwards compatability without choosing a new name for the new module that doesn't export the names in question.
Personally, I'd like more finer-grained modules, avoiding generic terms such as "extras" as they just end up as grab-bags full of things, and looking for a function involves searching the list of modules for a specific module and then searching "extras" if you can't find it. In other words, I propose that the rule used to decide what granularity to use should be to put oneself in the shoes of somebody looking for any of the functions in a module, and seeing if all of those functions would seem to be implied by its name, without it misleadingly suggesting any functions that are elsewhere.
[2014-05-02 02:47:55 UTC] iraikov wrote:
Does anyone want to propose a new structure for the core libraries?
Replying to felix: > The current structure of the libraries is completely arbitrary and both annoyingly impractical and inconsistent. `identity` doesn't belong into `data-structures` and why is `write-line` in `extras` and not in `ports`. The list goes on like this.
[2014-05-12 21:57:46 UTC] evhan wrote:
https://wiki.call-cc.org/core-libraries-reorganization created.
[2014-05-13 02:47:58 UTC] iraikov wrote:
I like the idea of hierarchical R7RS style libraries quite a bit.
Replying to evhan: > https://wiki.call-cc.org/core-libraries-reorganization created.
[2015-08-27 09:27:03 UTC] sjamaan set milestone to 5.0
[2015-08-27 09:27:03 UTC] sjamaan wrote:
Looks like we'll finally get around to it :)
[2018-03-18 22:58:06 UTC] sjamaan changed status from new to closed
[2018-03-18 22:58:06 UTC] sjamaan removed difficulty
[2018-03-18 22:58:06 UTC] sjamaan set resolution to fixed
[2018-03-18 22:58:06 UTC] sjamaan wrote:
We finally managed to restructure all the core libs!