Closed
Bug 1383920
Opened 7 years ago
Closed 7 years ago
MOZ_FALLTHROUGH does not avoid -Wimplicit-fallthrough warning with GCC 7
Categories
(Core :: MFBT, defect)
Tracking
()
RESOLVED
DUPLICATE
of bug 1355692
People
(Reporter: botond, Unassigned)
Details
When compiling m-c with GCC 7, I see warnings like this: 0:17.55 In file included from /home/botond/dev/projects/mozilla/central/obj-x86_64-pc-linux-gnu/gfx/layers/Unified_cpp_gfx_layers2.cpp:56:0: 0:17.55 /home/botond/dev/projects/mozilla/central/gfx/layers/apz/src/GestureEventListener.cpp: In member function ‘void mozilla::layers::GestureEventListener::HandleInputTimeoutLongTap()’: 0:17.55 /home/botond/dev/projects/mozilla/central/gfx/layers/apz/src/GestureEventListener.cpp:530:28: warning: this statement may fall through [-Wimplicit-fallthrough=] 0:17.55 CancelMaxTapTimeoutTask(); 0:17.55 ~~~~~~~~~~~~~~~~~~~~~~~^~ 0:17.55 /home/botond/dev/projects/mozilla/central/gfx/layers/apz/src/GestureEventListener.cpp:532:3: note: here 0:17.55 case GESTURE_FIRST_SINGLE_TOUCH_MAX_TAP_DOWN: { 0:17.55 ^~~~ The affected code *does* have a MOZ_FALLTHROUGH annotation, but that macro expands to nothing when compiling with GCC. It appears the thing it should expand to is [[gnu::fallthrough]].
Updated•7 years ago
|
Status: NEW → RESOLVED
Closed: 7 years ago
Resolution: --- → DUPLICATE
You need to log in
before you can comment on or make changes to this bug.
Description
•