/pidgin/main: a9d3726c3a8f: Clang warnings: clean up libpurple
twasilczyk at pidgin.im
Sun Oct 6 04:14:35 EDT 2013
2013/10/6 Mark Doliner <mark at kingant.net>:
> Hey Tomasz, I have some questions about this commit. I can't quote all
> the changes because the diff was truncated, but basically:
> 1. For the places where you cast an 8 bit variable to an int before
> printing it, could you remove the cast and print it using "%hhx"? Or
> is Clang not ok with that for some reason? Casting tends to hide
> problems and I think the code is cleaner without it.
%hhx doesn't seems to be supported on win32. See my previous commit .
> 2. What's the reason for casting aimutil_put32() to void? What was
> Clang complaining about?
Clang throws a warning on unused expression (not function) result. And
aimutil_put32 is a macro expanding to (something(),something(),4).
Casting to void just silences it. I don't think it's a problem,
because its output is definitely constant.
More information about the Devel