Hi all,

Quick question: was the SDCC standard library printf() implementation for the %p conversion specifier written only with little-endian platforms (e.g. 8051) in mind?

I ask because I encounter once again today an annoyance I've encountered before when working on big-endian target platforms such as the STM8. Whenever you use %p, the pointer value is formatted with the bytes in the wrong order. For example, a pointer with value of 0x87A1 is output as "0xa187". It's annoying to have to mentally transpose the bytes when looking at debugging output.

Regards,
Basil Hussain


_______________________________________________
Sdcc-user mailing list
Sdcc-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/sdcc-user

Reply via email to