Commit b6f1833
Fix unreachable-break issue in cinderx/Jit/lir/generator.cpp +5
Summary:
LLVM has a warning `-Wunreachable-code-break` which identifies `break` statements that cannot be reached. These compromise readability, are misleading, and may identify bugs. This diff removes such statements.
Such statements once existed to prevent accidental fallthroughs in switch statements. However, this is no longer necessary in C++17 because `[[fallthrough]]` is used to indicate intentional fallthroughs and we raise compilation errors for fallthroughs that are not annotated with `[[fallthrough]]` using `-Wimplicit-fallthrough`.
For questions/comments, contact r-barnes.
- If you approve of this diff, please use the "Accept & Ship" button :-)
Reviewed By: dtolnay
Differential Revision: D78276025
fbshipit-source-id: bf2543b9c6e61b7a934e8eaf6510d8a3092c51611 parent 9884521 commit b6f1833
2 files changed
Lines changed: 0 additions & 6 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
821 | 821 | | |
822 | 822 | | |
823 | 823 | | |
824 | | - | |
825 | 824 | | |
826 | 825 | | |
827 | 826 | | |
| |||
883 | 882 | | |
884 | 883 | | |
885 | 884 | | |
886 | | - | |
887 | 885 | | |
888 | 886 | | |
889 | 887 | | |
| |||
926 | 924 | | |
927 | 925 | | |
928 | 926 | | |
929 | | - | |
930 | 927 | | |
931 | 928 | | |
932 | 929 | | |
| |||
1120 | 1117 | | |
1121 | 1118 | | |
1122 | 1119 | | |
1123 | | - | |
1124 | 1120 | | |
1125 | 1121 | | |
1126 | 1122 | | |
| |||
1169 | 1165 | | |
1170 | 1166 | | |
1171 | 1167 | | |
1172 | | - | |
1173 | 1168 | | |
1174 | 1169 | | |
1175 | 1170 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
371 | 371 | | |
372 | 372 | | |
373 | 373 | | |
374 | | - | |
375 | 374 | | |
376 | 375 | | |
377 | 376 | | |
| |||
0 commit comments