public inbox for gcc-prs@sourceware.org help / color / mirror / Atom feed
From: Gert-jan Los <los@rz.uni-mannheim.de> To: gcc-gnats@gcc.gnu.org Subject: middle-end/4907: ICE on premature use of reference Date: Wed, 14 Nov 2001 10:27:00 -0000 [thread overview] Message-ID: <E165vtr-0002Gj-00@snoopy.rz.uni-mannheim.de> (raw) >Number: 4907 >Category: middle-end >Synopsis: ICE if a reference is used during its own definition >Confidential: no >Severity: serious >Priority: medium >Responsible: unassigned >State: open >Class: ice-on-illegal-code >Submitter-Id: net >Arrival-Date: Mon Nov 19 13:26:01 PST 2001 >Closed-Date: >Last-Modified: >Originator: Gert-jan Los >Release: 3.1 20011113 (experimental) >Organization: Universitaet Mannheim >Environment: System: Linux snoopy 2.2.19 #1 Thu May 31 15:16:55 CEST 2001 sparc unknown Architecture: sparc host: sparc-unknown-linux-gnu build: sparc-unknown-linux-gnu target: sparc-unknown-linux-gnu configured with: /users/los/admin/software/gcc/snapshot/configure --prefix=/opt/devel --with-as=/opt/devel/bin/as --with-ld=/opt/devel/bin/ld --disable-threads --disable-nls --enable-languages=c,c++ --enable-long-long >Description: Compiling the presumably invalid code below gives an ICE on mainline and 2.95.x. gcc version 3.1 20011113 (experimental) : In function `int main()': :4: Internal compiler error in make_decl_rtl, at varasm.c:834 gcc version 2.95.4 20011006 (Debian prerelease) : In function `int main()': :4: Internal compiler error: :4: Internal compiler error in `expand_expr', at expr.c:5852 gcc version 3.0.2 (Debian) Compiles OK. The value of c is 0 (zero). Changing the code to return 'x' instead '&x' results in a segmentation fault at runtime. >How-To-Repeat: int foo(int const& x) { return int(&x); } int main() { int const& c = foo(c); return 0; } >Fix: >Release-Note: >Audit-Trail: >Unformatted:
reply other threads:[~2001-11-19 21:26 UTC|newest] Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=E165vtr-0002Gj-00@snoopy.rz.uni-mannheim.de \ --to=los@rz.uni-mannheim.de \ --cc=gcc-gnats@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: linkBe 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).