| Summary: | "No break at the end of this case" checker needs to be smarter | ||
|---|---|---|---|
| Product: | [Tools] CDT | Reporter: | Sergey Prigogin <eclipse.sprigogin> |
| Component: | cdt-codan | Assignee: | Elena Laskavaia <elaskavaia.cdt> |
| Status: | RESOLVED FIXED | QA Contact: | Elena Laskavaia <elaskavaia.cdt> |
| Severity: | normal | ||
| Priority: | P3 | CC: | cdtdoug, malaperle |
| Version: | 8.0 | ||
| Target Milestone: | 8.0 | ||
| Hardware: | PC | ||
| OS: | All | ||
| Whiteboard: | |||
An empty case at the end of the switch should be treated differently from an empty case preceding another case. It makes sense to show no warnings in the following code by default: switch (i) { case 1: case 2: // do something break; } but show a warning in: switch (i) { case 1: // do something break; case 2: }