TDPL reaches Thermopylae level

Jeremie Pelletier jeremiep at gmail.com
Mon Oct 26 12:37:30 PDT 2009


Andrei Alexandrescu wrote:
> Bill Baxter wrote:
>> On Mon, Oct 26, 2009 at 8:47 AM, Jeremie Pelletier 
>> <jeremiep at gmail.com> wrote:
>>> Andrei Alexandrescu wrote:
>>>> 303 pages and counting!
>>>>
>>>> Andrei
>>> Soon the PI level, or at least 10 times PI!
>>>
>>
>> A hundred even. ;-)
> 
> Coming along. I'm writing about strings and Unicode right now. I was 
> wondering what people think about allowing concatenation (with ~ and ~=) 
> of strings of different character widths. The support library could do 
> all of the transcoding.
> 
> (I understand that concatenating an array of wchar or char with a dchar 
> is already in bugzilla.)
> 
> 
> Andrei

I don't know if thats a good idea, its better when string encoding is 
explicit so you know where your reallocations are.

ie if I know some routine will have to convert a utf16 parameter to utf8 
to append it to a string, then ill try and either make it output utf16 
or input utf8. If its implicit its much harder to find and optimize 
these cases.

to!string() is easy enough to use anyways.

But it could be good to add a range type that does this with multiple 
opAppend/opAppendAssign overloads.



More information about the Digitalmars-d mailing list