public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "joseph at codesourcery dot com" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug c++/772] Statement expressions issues
Date: Fri, 09 Sep 2005 15:41:00 -0000	[thread overview]
Message-ID: <20050909154146.1923.qmail@sourceware.org> (raw)
In-Reply-To: <20001111043600.772.jsm28@gcc.gnu.org>


------- Additional Comments From joseph at codesourcery dot com  2005-09-09 15:41 -------
Subject: Re:  Statement expressions issues

On Fri, 9 Sep 2005, rguenth at gcc dot gnu dot org wrote:

> No testcase?  But I think this is fixed on the mainline and only pending on 4.0.
> See PR17913.

The test is gcc.dg/stmt-expr-label-*.c (modulo the exact diagnostic text) 
and I don't think this is fixed for C++ on mainline.  This is separate 
from bug 17913 where there is a case which is valid at compile time and 
invalid at runtime, involving computed gotos: 
gcc.c-torture/compile/pr17913.c, which formerly ICEd with optimization but 
was fixed not to do so (at least for C; appears fixed for C++ as well with 
the mainline/4.0 compilers I have to hand to test but they are rather 
old).  It just happens that almost all cases of bug 17913 were addressed 
for C by fixing bug 772 for C, leaving only the case of computed gotos to 
be fixed separately in 17913 (for C).

The rules for invalidity for jumps into statement expressions are much the 
same as those in C++ for jumps bypassing initializations (imagining that 
each statement expression starts with such an initialization); it might be 
possible to reuse that code to fix this bug for C++.



-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=772


  parent reply	other threads:[~2005-09-09 15:41 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <20001111043600.772.jsm28@gcc.gnu.org>
2005-03-30 19:56 ` [Bug c/772] " cvs-commit at gcc dot gnu dot org
2005-03-30 19:59 ` cvs-commit at gcc dot gnu dot org
2005-03-31  7:26 ` [Bug c++/772] " pinskia at gcc dot gnu dot org
2005-04-03 18:56 ` pinskia at gcc dot gnu dot org
2005-09-09 12:38 ` rguenth at gcc dot gnu dot org
2005-09-09 15:41 ` joseph at codesourcery dot com [this message]
     [not found] <bug-772-4@http.gcc.gnu.org/bugzilla/>
2011-11-23 19:39 ` 3dw4rd at verizon dot net
2021-01-19 13:57 ` jakub at gcc dot gnu.org
2021-01-19 13:58 ` jakub at gcc dot gnu.org
2021-01-20  9:37 ` jakub at gcc dot gnu.org
2021-07-22 21:57 ` pinskia at gcc dot gnu.org
2021-07-22 21:57 ` pinskia at gcc dot gnu.org
2021-07-22 21:58 ` pinskia at gcc dot gnu.org
2021-07-22 23:16 ` pinskia at gcc dot gnu.org
2022-07-23 10:54 ` egallager at gcc dot gnu.org
2022-10-03 16:41 ` pinskia at gcc dot gnu.org
2022-12-01  8:41 ` egallager at gcc dot gnu.org

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20050909154146.1923.qmail@sourceware.org \
    --to=gcc-bugzilla@gcc.gnu.org \
    --cc=gcc-bugs@gcc.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).