The to!string conversion template doesn't handle const int or long values i.e. const h = 6; string s = to!string(h); // Error This seems to effect text, but not writeln. Patch: change u /= 10; to u = u / 10; inside /// Signed values ($(D int) and $(D long)). T to(T, S)(S value) if (staticIndexOf!(Unqual!S, int, long) >= 0 && isSomeString!T) Line# 2580 in dmd 2.032
Better patch: changing auto u = -cast(Unsigned!S) value; to auto u = -cast(Unsigned!(typeof(value+0))) value; on line 2575;
(In reply to comment #1) (maybe) more better patch: 2575: auto u = -cast(Unqual!(Unsigned!S)) value; Just you need is removing qualifier from S. std.traits.Unqual is the best way to do it.
(In reply to comment #2) > (In reply to comment #1) > (maybe) more better patch: > > 2575: auto u = -cast(Unqual!(Unsigned!S)) value; > > Just you need is removing qualifier from S. > std.traits.Unqual is the best way to do it. Fixed as you suggested, coming with 2.033. Thanks!
Fixed dmd 2.033