Fix -Wimplicit-fallthrough warnings in widget/cocoa

RESOLVED FIXED in Firefox 44

Status

()

RESOLVED FIXED
3 years ago
3 years ago

People

(Reporter: cpeterson, Assigned: cpeterson)

Tracking

unspecified
mozilla44
Points:
---
Dependency tree / graph

Firefox Tracking Flags

(firefox44 fixed)

Details

Attachments

(1 attachment)

(Assignee)

Description

3 years ago
Created attachment 8676027 [details] [diff] [review]
MOZ_FALLTHROUGH_widget_cocoa.patch

MOZ_FALLTHROUGH is an annotation to suppress clang's -Wimplicit-fallthrough warnings about switch cases that fall through without a break or return statement. MOZ_FALLTHROUGH is only needed on cases that have code:

switch (foo) {
  case 1: // These cases have no code. No fallthrough annotations are needed.
  case 2:
  case 3:
    foo = 4; // This case has code, so a fallthrough annotation is needed:
    MOZ_FALLTHROUGH;
  default:
    return foo;
}

widget/cocoa/nsChildView.mm:1664:5 [-Wimplicit-fallthrough] unannotated fall-through between switch labels

widget/cocoa/nsChildView.mm:1761:5 [-Wimplicit-fallthrough] unannotated fall-through between switch labels

widget/cocoa/nsNativeThemeCocoa.mm:3700:5 [-Wimplicit-fallthrough] unannotated fall-through between switch labels
Attachment #8676027 - Flags: review?(spohl.mozilla.bugs)
Attachment #8676027 - Flags: review?(spohl.mozilla.bugs) → review+
https://hg.mozilla.org/mozilla-central/rev/1117b2bc65c2
Status: NEW → RESOLVED
Last Resolved: 3 years ago
status-firefox44: --- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla44
(Assignee)

Updated

3 years ago
Blocks: 1253170
You need to log in before you can comment on or make changes to this bug.