Dynamic arrays in D 1.0

Edward Diener eddielee_no_spam_here at tropicsoft.com
Sun May 11 14:55:16 PDT 2008


bearophile wrote:
> Edward Diener:
>> I see the Phobos std.string. It seems, at first glance, not nearly as 
>> rich an implementation as the C++ std::string functionality.
> 
> A module of strings functions and the like is a work of the art of balance. More isn't always better. You have to put there the best/right functions, and throw away the useless ones, the more confusing ones, etc etc.

I am one of those who really likes the C++ std::string class. I would 
not have chosen all the redundancy with C strings in the various 
functionality, since a std::string can always be constructed from a C 
string, but other than that I think it is excellent. I don't understand 
why D would not have wanted to create a std.string which mirrors that 
functionality, leaving out the C-isms except for construction. Maybe I 
will just do it myself and post it somewhere as I play around with D 
some more.

I think D has sometime tried not to be C++ to its detriment, and this is 
one more case of that ( there are plenty others ).



More information about the Digitalmars-d mailing list