Issue with template function
Charles via Digitalmars-d-learn
digitalmars-d-learn at puremagic.com
Sat Feb 7 01:10:15 PST 2015
On Friday, 6 February 2015 at 17:40:31 UTC, ketmar wrote:
> On Fri, 06 Feb 2015 17:09:28 +0000, Charles wrote:
>
>> readString(toBytes!string("test"),0,4).writeln;
>
> if you'll take a look into druntime sources, you'll find that
> string is
> just an alias to `immutable(char)[]`. so you actually doing
> thing:
>
> readString(toBytes!(immutable(char)[])("test"),0,4).writeln;
>
> i bet that this is not what you meant. ;-)
Thanks!
More information about the Digitalmars-d-learn
mailing list