https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64619
Bug ID: 64619 Summary: No -Wsign-conversion warning Product: gcc Version: 5.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c Assignee: unassigned at gcc dot gnu.org Reporter: chengniansun at gmail dot com I think "a" should be converted to unsigned long, so there is a signedness change in this expression. $: cat s.c int a; void fn() /* */ { a ^ 0x1UL; } $: $: gcc-trunk -Wsign-conversion s.c -c $: $: clang-trunk -Wno-unused-value -Wsign-conversion s.c -c s.c:4:3: warning: implicit conversion changes signedness: 'int' to 'unsigned long' [-Wsign-conversion] a ^ 0x1UL; ^ ~ 1 warning generated. $: $: