[Bug c/113414] Incorrent checking for printf format: does not distinguish whether the variable is signed or unsigned

2024-01-15 Thread egallager at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=113414 Eric Gallager changed: What|Removed |Added CC||egallager at gcc dot gnu.org

[Bug c/113414] Incorrent checking for printf format: does not distinguish whether the variable is signed or unsigned

2024-01-15 Thread xry111 at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=113414 Xi Ruoyao changed: What|Removed |Added CC||xry111 at gcc dot gnu.org --- Comment #3

[Bug c/113414] Incorrent checking for printf format: does not distinguish whether the variable is signed or unsigned

2024-01-15 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=113414 Andrew Pinski changed: What|Removed |Added Resolution|--- |INVALID See Also|

[Bug c/113414] Incorrent checking for printf format: does not distinguish whether the variable is signed or unsigned

2024-01-15 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=113414 --- Comment #1 from Andrew Pinski --- >The code should be warned, but it did not. No that is by design. You need to use -Wformat-signedness for that. But for the second example, the fix it note is wrong only with -Wformat-signedness .