|
Bugzilla – Full Text Bug Listing |
| Summary: | gcc13 fails to recognize range of values in switch statement | ||
|---|---|---|---|
| Product: | [openSUSE] openSUSE Tumbleweed | Reporter: | Olaf Hering <ohering> |
| Component: | Basesystem | Assignee: | Richard Biener <rguenther> |
| Status: | NEW --- | QA Contact: | E-mail List <qa-bugs> |
| Severity: | Normal | ||
| Priority: | P5 - None | ||
| Version: | Current | ||
| Target Milestone: | --- | ||
| Hardware: | x86-64 | ||
| OS: | Linux | ||
| See Also: | https://gcc.gnu.org/bugzilla/show_bug.cgi?id=110839 | ||
| Whiteboard: | |||
| Found By: | --- | Services Priority: | |
| Business Priority: | Blocker: | --- | |
| Marketing QA Status: | --- | IT Deployment: | --- |
| Attachments: | source_genCases_f16.c.i.xz | ||
The diagnostic happens before optimization and thus analysis of all case values and an unreachable 'default' case is emitted by gimplification. Reported upstream. You can put __builtin_unreachable (); after the switch to silence the diagnostic. |
Created attachment 868399 [details] source_genCases_f16.c.i.xz random_ui8 returns an unsigned char. (u8 & 7) means values between zero and seven need to be handled. genCases_f16.c: In function 'f16Random': genCases_f16.c:336:1: error: control reaches end of non-void function [-Werror=return-type]