Skip to content

Commit 916e53f

Browse files
NSProgrammermeta-codesync[bot]
authored andcommitted
Fix implicit fallthrough in switch statements (facebook#54290)
Summary: Pull Request resolved: facebook#54290 A few places where we fall through intentionally are implicit. We can make those explicit with `NS_FALLTHROUGH`. Many places, however, are bugs from failing to add a `break` :eek: -- fix those places too. These are all found via `-Wimplicit-fallthrough`... we will seek to make this an error by default (vs only in `CompilerWarningLevel.MEDIUM` or higher). ## Changelog: [iOS] [Fixed] - Add missing `break;` to `-[RCTViewManager pointerEvents]` Reviewed By: philIip Differential Revision: D85583441 fbshipit-source-id: e8959b27a2e23ccfc6581286257d5d41b18c5630
1 parent 363d297 commit 916e53f

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

packages/react-native/React/Views/RCTViewManager.m

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -341,11 +341,13 @@ - (void)updateAccessibilityTraitsForRole:(RCTView *)view withDefaultView:(RCTVie
341341
// Unspecified values do not.
342342
// This wouldn't override a container view's `userInteractionEnabled = NO`
343343
view.userInteractionEnabled = YES;
344+
break;
344345
case RCTPointerEventsNone:
345346
view.userInteractionEnabled = NO;
346347
break;
347348
default:
348349
RCTLogInfo(@"UIView base class does not support pointerEvent value: %@", json);
350+
break;
349351
}
350352
}
351353
RCT_CUSTOM_VIEW_PROPERTY(removeClippedSubviews, BOOL, RCTView)

0 commit comments

Comments
 (0)