PikaPython icon indicating copy to clipboard operation
PikaPython copied to clipboard

Fix incorrect printf format specifier

Open szsam opened this issue 1 year ago • 1 comments

PRI macros should be used for uintptr_t. Calling a printf-like function with the wrong type of arguments causes unpredictable behavior.

szsam avatar Mar 27 '24 23:03 szsam

I am not sure if <inttypes.h> can be used on various embedded platforms, such as stm32 and other MCU SDKs. This requires some testing, and I will validate these platforms when I have time, so this pull request will be delayed. It would be even better if you could help with testing.

pikasTech avatar Mar 28 '24 04:03 pikasTech

As <inttypes.h> was added to C99 and tested on mdk-arm and AIR, this PR would be merged.

pikasTech avatar Aug 15 '24 15:08 pikasTech