public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/98750] New: does not detect dead code
@ 2021-01-19 18:57 tiagomacarios at gmail dot com
  2021-01-19 19:49 ` [Bug c++/98750] " redi at gcc dot gnu.org
                   ` (6 more replies)
  0 siblings, 7 replies; 8+ messages in thread
From: tiagomacarios at gmail dot com @ 2021-01-19 18:57 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=98750

            Bug ID: 98750
           Summary: does not detect dead code
           Product: gcc
           Version: 11.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c++
          Assignee: unassigned at gcc dot gnu.org
          Reporter: tiagomacarios at gmail dot com
  Target Milestone: ---

for the following code gcc will not detect that f() is never called. msvc
detects this correctly.

https://godbolt.org/z/Y5n78v
```
void f();

void _(int num) {
    switch (num)
    {
        case 1:
            break;
            f();
    }
}
```

^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2021-11-24 19:06 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-01-19 18:57 [Bug c++/98750] New: does not detect dead code tiagomacarios at gmail dot com
2021-01-19 19:49 ` [Bug c++/98750] " redi at gcc dot gnu.org
2021-01-20  7:56 ` marxin at gcc dot gnu.org
2021-01-20 20:59 ` tiagomacarios at gmail dot com
2021-01-21 10:18 ` redi at gcc dot gnu.org
2021-08-17  9:05 ` pinskia at gcc dot gnu.org
2021-10-27  5:08 ` [Bug c++/98750] does not detect dead code [-Wunreachable-code-break] egallager at gcc dot gnu.org
2021-11-24 19:06 ` egallager at gcc dot gnu.org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).