Am Wed, 06 Feb 2013 23:06:06 -0500 schrieb Chad Joan <[email protected]>:
> I just want to say "PLEASE YES". Phobos' module hierarchy is currently > confusing at best, especially with various important elements being > scattered across std.range, std.algorithm, std.array, and maybe another > I'm forgetting. Although I can sort of see the logic behind this > convention, it is very hard to think of a function that operates on > ranges and automatically know which module to look in. I'm rambling, sorry. > > PLEASE YES! It is true. I've had the same discussion on IRC a while ago. After letting off some steam, I had the idea to make a map of Phobos by functionality instead of module. Sometimes simple stuff confuses me: is .empty in std.array or std.range? And why is it not a standard property of arrays? The module borders seem washy in std.rangorithray. String formatting is another example with functions spread over conv/string/format for: 'xformat' (std.string), 'text' (std.conv) or 'formattedWrite' (std.format). Add manipulation to the list and the function you look for may even be generalized in std.algorithm, like 'startsWith'. String slicing/concatenation: 'stripRight' (std.string), 'startsWith' (std.algorithm), 'join' (std.array) Text I/O: 'readText' (std.file), 'byLine' (std.stdio) Temporary files: 'tmpfile' (std.stdio), 'tempDir' (std.file) Charsets: 'toMBSz' (std.windows.charset), 'transcode' (std.encoding), 'toUTF16' (std.utf) Memory streams: 'MemoryStream' (std.stream), 'OutBuffer' (std.outbuffer) ... and so on ... -- Marco
