writefln question

pmoore pmoore_member at pathlink.com
Fri Mar 17 15:59:45 PST 2006


I can't give a number which is < 10 a precision. Is there a good reason for this
or is this a bug?

eg.

writefln("number = %.8x", cast(ulong)10);

will display 

0000000a

but 

writefln("number = %.8x", cast(ulong)9);

will display

9

Why is the precision ignored in this case?

printf does not work this way. It will correctly display 00000009 





More information about the Digitalmars-d-learn mailing list