New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We鈥檒l occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix compiler warnings due to integer type mismatch #2722
Conversation
I like this solution, thank you! Could you apply it to the other files too that are mentioned in #2705? |
we can catch more similar warnings if we enable CI for arm/xtensa target. |
It'd be great to have ARM/Xtensa CI tests too. Contribution would be welcome on it 馃檪 |
For sure, no problem. |
Thank you! |
@mysterywolf |
I think this PR's method is better than both of ours: lvgl/lv_demos#146 . How do you think? By the way, could you please help me to review this PR: #2919 @FASTSHIFT |
I agree with you. |
* fix:Removed string format warnings for int32_t and uint32_t re-handle #2722 * feat(rt-thread): add the option of built-in examples
Description of the feature or fix
This PR will silence the warning:
This is an awkward situation: some compilers think that uint32_t is
long unsigned int
(which means %lu should be used), and some of those think that uint32_t isunsigned int
(which means %u should be used).Thus, I think the best solution is to use
unsigned int
to replaceuint32_t
, and use%u
to replace%d
. Every compiler is happy.馃槀Checkpoints