public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
* [Bug middle-end/86284] Insert trap instruction in place of missing return statement on dodgy code [not found] <bug-86284-4@http.gcc.gnu.org/bugzilla/> @ 2021-07-24 9:57 ` pinskia at gcc dot gnu.org 2021-07-24 9:59 ` pinskia at gcc dot gnu.org 1 sibling, 0 replies; 2+ messages in thread From: pinskia at gcc dot gnu.org @ 2021-07-24 9:57 UTC (permalink / raw) To: gcc-bugs https://gcc.gnu.org/bugzilla/show_bug.cgi?id=86284 --- Comment #4 from Andrew Pinski <pinskia at gcc dot gnu.org> --- (In reply to Andrew Pinski from comment #3) > I thought it was defined unless the return value is actually used. To answer my own question: For C it is. For C++ it is not; it is undefined if there is no return value. ^ permalink raw reply [flat|nested] 2+ messages in thread
* [Bug middle-end/86284] Insert trap instruction in place of missing return statement on dodgy code [not found] <bug-86284-4@http.gcc.gnu.org/bugzilla/> 2021-07-24 9:57 ` [Bug middle-end/86284] Insert trap instruction in place of missing return statement on dodgy code pinskia at gcc dot gnu.org @ 2021-07-24 9:59 ` pinskia at gcc dot gnu.org 1 sibling, 0 replies; 2+ messages in thread From: pinskia at gcc dot gnu.org @ 2021-07-24 9:59 UTC (permalink / raw) To: gcc-bugs https://gcc.gnu.org/bugzilla/show_bug.cgi?id=86284 --- Comment #5 from Andrew Pinski <pinskia at gcc dot gnu.org> --- -fsanitize=unreachable will find the C++ cases right now. For C, it is a little harder because it is only undefined if the value is used. ^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2021-07-24 9:59 UTC | newest] Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- [not found] <bug-86284-4@http.gcc.gnu.org/bugzilla/> 2021-07-24 9:57 ` [Bug middle-end/86284] Insert trap instruction in place of missing return statement on dodgy code pinskia at gcc dot gnu.org 2021-07-24 9:59 ` pinskia 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).