D BUGS Part 2

bearophile bearophileHUGS at lycos.com
Thu Jan 1 23:53:23 PST 2009


Bill Baxter

>What you've written seems more like a list of enhancements than bugs.<

Seeing how for example complex numbers are written by writefln, I can't agree, but I presume it doesn't matter.
(But I essentially refuse to use D without improved and fixed printing/string-fying functions like the ones I have written and use.)


>I think that's a fine goal, but it's clearly not a goal of writef/writefln.<

Time to change its goal then, because it will help to program faster and in a safer way.


>Making writefln automatically generate a default representation of structs instead of erroring out would be a great.<

It works with classes too, even if it's a little less useful, and partially with unions too (as much as possible).


>It hasn't bitten me since then.<

Probably because D is statically typed, so reading code you usually can eventually understand the types of the data inside collections.
But using higher-level functions to programm, like the map, filter, select, apply, etc, and all their lazy variants, you let the compiler manage types more automatically (and you may even have nested lazy generators), in such situation having a clean printout becomes more important.

Bye,
bearophile



More information about the Digitalmars-d mailing list