Silence warning on comma misuse - #13392
Conversation
Building curl with -Wcomma, I see warnings about "possible misuse of comma operator here" and moving fields assignment out of the for() fixes it.
another one
|
Thanks, I think this is a step towards less clever and more readable code. I'll just let CI have a look before pushing. |
|
We should probably add |
|
Turns out we already do (with clang)! @MonkeybreadSoftware are you perhaps using a very recent clang with perhaps some changes for this warning? |
|
Sorry, this is just my test project in Xcode 15.3 to work on curl changes in the IDE. Maybe your CI with Xcode 14 doesn't report this. |
This is a clang option added in 3.9 and we build with this option in several builds. Totally independent of xcode. I have no idea why they don't warn on these. |
|
Thanks! |
Building curl with -Wcomma, I see warnings about "possible misuse of comma operator here" and moving fields assignment out of the for() fixes it.