On Wed, Jun 27, 2012 at 5:38 PM, Timon Gehr <[email protected]> wrote:

> On 06/27/2012 03:25 PM, Gor Gyolchanyan wrote:
>
>> Are there functions, which wrap arbitrary range types into standard
>> range interfaces?
>> I looked at the docs, but couldn't find anything.
>> Use case:
>>
>> RandomAccessRange!dchar s = ???("Hello, world!");
>>
>> --
>> Bye,
>> Gor Gyolchanyan.
>>
>
> A narrow string is not a RandomAccessRange.
>
> RandomAccessFinite!(immutable(**dchar)) s = inputRangeObject("Hello,
> world!"d);
>

I tested it out and the string literal without qualifiers counts as a
dstring.

-- 
Bye,
Gor Gyolchanyan.

Reply via email to