Idea: Introduce zero-terminated string specifier
Muhtar
lone at gmail.com
Sun Sep 30 14:11:40 PDT 2012
On Sunday, 30 September 2012 at 19:58:16 UTC, Vladimir Panteleev
wrote:
> On Sunday, 30 September 2012 at 18:31:00 UTC, deadalnix wrote:
>> If you know that a string is 0 terminated, you can easily
>> create a slice from it as follow :
>>
>> char* myZeroTerminatedString;
>> char[] myZeroTerminatedString[0 ..
>> strlen(myZeroTerminatedString)];
>>
>> It is clean and avoid to modify the stdlib in an unsafe way.
>
> That's what to!string already does.
I aggere you... <a
href="http://www.tercumesirketi.com/">Tercüme</a> || <a
href="http://www.tercumesirketi.com/">Tercüme Büroları</a>
More information about the Digitalmars-d
mailing list