std.string and ranges

bearophile bearophileHUGS at lycos.com
Sun Feb 8 13:14:12 PST 2009


Andrei Alexandrescu:
> Yes, std.string must be revamped too.

>From what you say in several of your last posts it seems std will be almost fully rewritten.

I think this is positive, and while sometimes I think D2 language (and its std lib) is becoming too much complex for my tastes (I have appreciated D1 a lot because it's simple enough and it gives me quite more than what I give to it. D2 asks me quite more, but gives me a bit more), I like and silently agree with most of the things you want to do to improve the std lib.
It seems D2 is becoming a language really different from D1, so I think Tango for D2 will need very large changes.

It may be positive to copy few things from Tango, like BigInt, etc to the future std of D2.

I think the current std.random needs many changes (I have expressed my ideas on this in a past email but if you want I can say them again). I may want to work a little to help you develop such std lib of D2, for example the std.random, but sometimes the things you say seem a bit too much sophisticated for me, so I may not be able to help much in practice...

What I have recently said regarding the lazy generators can be applied to other things: having two ways to do things is generally bad, but if one of those ways is really easy and short to write and the other is very flexible and fast, then two ways to do something may coexist. For example this idea can applied to the foreach, the std.random, etc.

I also hope to see the printing function(s) of D2 improved in the ways I have explained you recently. The bad thing is that beside you I think no one else has expressed a comment regarding those functions. So I don't know if others like those ideas.

Bye,
bearophile



More information about the Digitalmars-d mailing list