On Wed, 18 Aug 2010 23:11:26 -0400, Rainer Deyke <rain...@eldwood.com>
wrote:
On 8/18/2010 20:37, dsimcha wrote:
I've been hacking in Phobos and parallelfuture and I've come to the
conclusion
that having typeof(c) in the expression foreach(c; string.init) not be
a dchar
is simply ridiculous.
I have long ago come to the opposite conclusion. An array of 'char'
should act like any other array. If you want a sequence of 'dchar' that
is internally stored as an array of 'char', don't call it 'char[]'.
I have to agree with Rainer here. I think maybe string shouldn't just be
an immutable(char)[]. I'd rather see it as a struct that wraps a char[]
and presents the appropriate interface.
Ditto for wchar.
-Steve