3 ms·
I think part of the issue is that different people expect different functionality from a "standard library". I see three logical divisions within the language w
by djacobs 16y ago
I think part of the issue is that different people expect different functionality from a "standard library". I see three logical divisions within the language we call "Ruby":
1. Core language - Definition of language syntax and literals, regular expressions, core data structures
2. Standard library - Functionality that is expected out of a programming language (not framework) - things like file reading, ERb, etc.
3. Standard protocols - A set of libraries with the default Ruby implementations for standard protocols - HTTP, JSON, SSL, OpenId, etc.
It seems to me like protocols don't belong in the same directory as libraries for basic local file operations, but maybe that's just me.
Either way, I think the standard library, while not a ghetto, could use more order and care.
- regularfry 16y ago> It seems to me like protocols don't belong in the same directory as libraries for basic local file operations They aren't. File is in core, net/http is in stdlib. FileUtils is in stdlib, but that's more about interaction with the filesystem than files themselves, and it's not necessary for every single ruby script the way File is. For the most part, I think the core/stdlib separation is ok. What I take issue with is the namespace organisation, especially in stdlib. I'd rather see a deeper hierarchy that avoids stomping on the top-level namespace than what we've got now, but that's a lot of work to reorganise.