Skip to content

Commit f65292e

Browse files
NSProgrammerfacebook-github-bot
authored andcommitted
Fix exhaustive switches
Summary: X-link: facebook/react-native#52379 Changelog: [General][Fixed] - Add `default:` case to avoid warnings/errors for targets that compile with `-Wswitch-enum` and `-Wswitch-default` enabled Reviewed By: aary, yungsters, astreet Differential Revision: D77051152 fbshipit-source-id: 100b10f97cb3a5d73f1e3dcaf1b284baf6a43982
1 parent 1d6fb02 commit f65292e

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

lib/yoga/src/main/cpp/yoga/YGValue.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -72,9 +72,9 @@ inline bool operator==(const YGValue& lhs, const YGValue& rhs) {
7272
case YGUnitPoint:
7373
case YGUnitPercent:
7474
return lhs.value == rhs.value;
75+
default:
76+
return false;
7577
}
76-
77-
return false;
7878
}
7979

8080
inline bool operator!=(const YGValue& lhs, const YGValue& rhs) {

0 commit comments

Comments
 (0)