public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/43875] New: gcc-4.5.0 - ICE on invalid lambda return
@ 2010-04-23 22:48 paul dot bibbings at gmail dot com
2010-04-23 22:50 ` [Bug c++/43875] " pinskia at gcc dot gnu dot org
` (3 more replies)
0 siblings, 4 replies; 5+ messages in thread
From: paul dot bibbings at gmail dot com @ 2010-04-23 22:48 UTC (permalink / raw)
To: gcc-bugs
The following code causes an ICE in gcc-4.5.0. An error should be reported (as
per n3092, 5.1.2/4) owing to the fact that the return statement is invalid - a
brace-init-list is not an expression and hence the return type is void.
23:38:33 Paul Bibbings@JIJOU
/cygdrive/d/CPPProjects/nano/gcc_bugs $cat _5_1_2_4.cpp
int main()
{
auto x2 = []{ return { 1, 2 }; };
}
23:39:08 Paul Bibbings@JIJOU
/cygdrive/d/CPPProjects/nano/gcc_bugs $i686-pc-cygwin-gcc-4.5.0 -Wall
-save-temps -std=c++0x -c _5_1_2_4.cpp
_5_1_2_4.cpp: In lambda function:
_5_1_2_4.cpp:3:32: internal compiler error: in convert_like_real, at
cp/call.c:4929
Please submit a full bug report,
with preprocessed source if appropriate.
See <http://gcc.gnu.org/bugs.html> for instructions.
23:43:24 Paul Bibbings@JIJOU
/cygdrive/d/CPPProjects/nano/gcc_bugs $i686-pc-cygwin-gcc-4.5.0 -v
Using built-in specs.
COLLECT_GCC=i686-pc-cygwin-gcc-4.5.0
COLLECT_LTO_WRAPPER=/opt/gcc-4.5.0/libexec/gcc/i686-pc-cygwin/4.5.0/lto-wrapper.exe
Target: i686-pc-cygwin
Configured with: ./configure --prefix=/opt/gcc-4.5.0 --enable-bootstrap
--enable-version-specific-runtime-libs --enable-static --enable-shared
--enable-shared-libgcc --disable-__cxa_atexit --with-gnu-ld --with-gnu-as
--with-dwarf2 --disable-sjlj-exceptions --enable-languages=c,c++
--disable-symvers --enable-libgomp --enable-libssp --enable-threads=posix
--with-arch-i686 --with-tune=generic
Thread model: posix
gcc version 4.5.0 (GCC)
23:44:15 Paul Bibbings@JIJOU
/cygdrive/d/CPPProjects/nano/gcc_bugs $cat _5_1_2_4.ii
# 1 "_5_1_2_4.cpp"
# 1 "<built-in>"
# 1 "<command-line>"
# 1 "_5_1_2_4.cpp"
int main()
{
auto x2 = []{ return { 1, 2 }; };
}
--
Summary: gcc-4.5.0 - ICE on invalid lambda return
Product: gcc
Version: 4.5.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c++
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: paul dot bibbings at gmail dot com
GCC host triplet: i686-pc-cygwin
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=43875
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug c++/43875] gcc-4.5.0 - ICE on invalid lambda return
2010-04-23 22:48 [Bug c++/43875] New: gcc-4.5.0 - ICE on invalid lambda return paul dot bibbings at gmail dot com
@ 2010-04-23 22:50 ` pinskia at gcc dot gnu dot org
2010-04-27 21:22 ` [Bug c++/43875] [C++0x] " jason at gcc dot gnu dot org
` (2 subsequent siblings)
3 siblings, 0 replies; 5+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2010-04-23 22:50 UTC (permalink / raw)
To: gcc-bugs
------- Comment #1 from pinskia at gcc dot gnu dot org 2010-04-23 22:50 -------
Confirmed.
--
pinskia at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |NEW
Ever Confirmed|0 |1
Keywords| |ice-on-invalid-code
Last reconfirmed|0000-00-00 00:00:00 |2010-04-23 22:50:08
date| |
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=43875
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug c++/43875] [C++0x] ICE on invalid lambda return
2010-04-23 22:48 [Bug c++/43875] New: gcc-4.5.0 - ICE on invalid lambda return paul dot bibbings at gmail dot com
2010-04-23 22:50 ` [Bug c++/43875] " pinskia at gcc dot gnu dot org
@ 2010-04-27 21:22 ` jason at gcc dot gnu dot org
2010-04-27 23:03 ` jason at gcc dot gnu dot org
2010-05-03 21:44 ` jason at gcc dot gnu dot org
3 siblings, 0 replies; 5+ messages in thread
From: jason at gcc dot gnu dot org @ 2010-04-27 21:22 UTC (permalink / raw)
To: gcc-bugs
------- Comment #2 from jason at gcc dot gnu dot org 2010-04-27 21:21 -------
Subject: Bug 43875
Author: jason
Date: Tue Apr 27 21:21:35 2010
New Revision: 158805
URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=158805
Log:
PR c++/43875
* semantics.c (lambda_return_type): Complain about
braced-init-list.
Added:
trunk/gcc/testsuite/g++.dg/cpp0x/lambda/lambda-deduce2.C
Modified:
trunk/gcc/cp/ChangeLog
trunk/gcc/cp/semantics.c
trunk/gcc/testsuite/ChangeLog
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=43875
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug c++/43875] [C++0x] ICE on invalid lambda return
2010-04-23 22:48 [Bug c++/43875] New: gcc-4.5.0 - ICE on invalid lambda return paul dot bibbings at gmail dot com
2010-04-23 22:50 ` [Bug c++/43875] " pinskia at gcc dot gnu dot org
2010-04-27 21:22 ` [Bug c++/43875] [C++0x] " jason at gcc dot gnu dot org
@ 2010-04-27 23:03 ` jason at gcc dot gnu dot org
2010-05-03 21:44 ` jason at gcc dot gnu dot org
3 siblings, 0 replies; 5+ messages in thread
From: jason at gcc dot gnu dot org @ 2010-04-27 23:03 UTC (permalink / raw)
To: gcc-bugs
------- Comment #3 from jason at gcc dot gnu dot org 2010-04-27 23:03 -------
Subject: Bug 43875
Author: jason
Date: Tue Apr 27 23:02:56 2010
New Revision: 158814
URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=158814
Log:
PR c++/43875
* semantics.c (lambda_return_type): Complain about
braced-init-list.
Added:
branches/gcc-4_5-branch/gcc/testsuite/g++.dg/cpp0x/lambda/lambda-deduce2.C
Modified:
branches/gcc-4_5-branch/gcc/cp/ChangeLog
branches/gcc-4_5-branch/gcc/cp/semantics.c
branches/gcc-4_5-branch/gcc/testsuite/ChangeLog
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=43875
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug c++/43875] [C++0x] ICE on invalid lambda return
2010-04-23 22:48 [Bug c++/43875] New: gcc-4.5.0 - ICE on invalid lambda return paul dot bibbings at gmail dot com
` (2 preceding siblings ...)
2010-04-27 23:03 ` jason at gcc dot gnu dot org
@ 2010-05-03 21:44 ` jason at gcc dot gnu dot org
3 siblings, 0 replies; 5+ messages in thread
From: jason at gcc dot gnu dot org @ 2010-05-03 21:44 UTC (permalink / raw)
To: gcc-bugs
------- Comment #4 from jason at gcc dot gnu dot org 2010-05-03 21:44 -------
Fixed for 4.5.1.
--
jason at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |RESOLVED
Resolution| |FIXED
Target Milestone|--- |4.5.1
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=43875
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2010-05-03 21:44 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-04-23 22:48 [Bug c++/43875] New: gcc-4.5.0 - ICE on invalid lambda return paul dot bibbings at gmail dot com
2010-04-23 22:50 ` [Bug c++/43875] " pinskia at gcc dot gnu dot org
2010-04-27 21:22 ` [Bug c++/43875] [C++0x] " jason at gcc dot gnu dot org
2010-04-27 23:03 ` jason at gcc dot gnu dot org
2010-05-03 21:44 ` jason at gcc dot gnu dot 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).