writef: How to output hex byte?

torhu no at spam.invalid
Sat Aug 28 22:16:59 PDT 2010


On 29.08.2010 07:06, Nick Sabalausky wrote:
> ubyte myByte = 0x09;
> writef("%%%.2X", myByte);
> writef("%%%02X", myByte);

On codepad.org (DMD 1.026 last time I checked), this prints this:
%09%09

So it's probably a bug in the new formatting code.  I assume it's 
supposed to follow the C behavior in this case.


More information about the Digitalmars-d-learn mailing list