* [Bug c++/54170] Call to lambda elided
2012-08-04 0:03 [Bug c++/54170] New: Call to lambda elided bekenn at yopmail dot com
@ 2012-08-04 0:07 ` paolo.carlini at oracle dot com
2012-08-04 10:48 ` redi at gcc dot gnu.org
` (14 subsequent siblings)
15 siblings, 0 replies; 17+ messages in thread
From: paolo.carlini at oracle dot com @ 2012-08-04 0:07 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54170
Paolo Carlini <paolo.carlini at oracle dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |WAITING
Last reconfirmed| |2012-08-04
Ever Confirmed|0 |1
--- Comment #1 from Paolo Carlini <paolo.carlini at oracle dot com> 2012-08-04 00:07:33 UTC ---
Can you please add a self contained testcase, not requiring assembly
inspection? Thanks.
^ permalink raw reply [flat|nested] 17+ messages in thread
* [Bug c++/54170] Call to lambda elided
2012-08-04 0:03 [Bug c++/54170] New: Call to lambda elided bekenn at yopmail dot com
2012-08-04 0:07 ` [Bug c++/54170] " paolo.carlini at oracle dot com
@ 2012-08-04 10:48 ` redi at gcc dot gnu.org
2012-08-04 11:35 ` paolo.carlini at oracle dot com
` (13 subsequent siblings)
15 siblings, 0 replies; 17+ messages in thread
From: redi at gcc dot gnu.org @ 2012-08-04 10:48 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54170
--- Comment #2 from Jonathan Wakely <redi at gcc dot gnu.org> 2012-08-04 10:47:49 UTC ---
Dup of PR 52988?
^ permalink raw reply [flat|nested] 17+ messages in thread
* [Bug c++/54170] Call to lambda elided
2012-08-04 0:03 [Bug c++/54170] New: Call to lambda elided bekenn at yopmail dot com
2012-08-04 0:07 ` [Bug c++/54170] " paolo.carlini at oracle dot com
2012-08-04 10:48 ` redi at gcc dot gnu.org
@ 2012-08-04 11:35 ` paolo.carlini at oracle dot com
2012-08-04 11:37 ` paolo.carlini at oracle dot com
` (12 subsequent siblings)
15 siblings, 0 replies; 17+ messages in thread
From: paolo.carlini at oracle dot com @ 2012-08-04 11:35 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54170
--- Comment #3 from Paolo Carlini <paolo.carlini at oracle dot com> 2012-08-04 11:35:34 UTC ---
Indeed, I suspected that immediately. But without a self contained testcase not
requiring inspection of the assembly personally I'm not 100% sure (and I'm in
the middle of 2-3 other things).
^ permalink raw reply [flat|nested] 17+ messages in thread
* [Bug c++/54170] Call to lambda elided
2012-08-04 0:03 [Bug c++/54170] New: Call to lambda elided bekenn at yopmail dot com
` (2 preceding siblings ...)
2012-08-04 11:35 ` paolo.carlini at oracle dot com
@ 2012-08-04 11:37 ` paolo.carlini at oracle dot com
2012-08-06 4:44 ` bekenn at yopmail dot com
` (11 subsequent siblings)
15 siblings, 0 replies; 17+ messages in thread
From: paolo.carlini at oracle dot com @ 2012-08-04 11:37 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54170
--- Comment #4 from Paolo Carlini <paolo.carlini at oracle dot com> 2012-08-04 11:37:12 UTC ---
If submitter can try current 4_7-branch or mainline, it would be easy for him
to double check.
^ permalink raw reply [flat|nested] 17+ messages in thread
* [Bug c++/54170] Call to lambda elided
2012-08-04 0:03 [Bug c++/54170] New: Call to lambda elided bekenn at yopmail dot com
` (3 preceding siblings ...)
2012-08-04 11:37 ` paolo.carlini at oracle dot com
@ 2012-08-06 4:44 ` bekenn at yopmail dot com
2012-08-06 4:46 ` bekenn at yopmail dot com
` (10 subsequent siblings)
15 siblings, 0 replies; 17+ messages in thread
From: bekenn at yopmail dot com @ 2012-08-06 4:44 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54170
--- Comment #5 from bekenn at yopmail dot com 2012-08-06 04:44:17 UTC ---
Created attachment 27948
--> http://gcc.gnu.org/bugzilla/attachment.cgi?id=27948
Full application showing issue.
Sorry for the wait. Here is a complete program showing the issue. Compiled
with:
g++ -std=gnu++0x -g lambdatest.cpp -o lambdatest.exe
Traces have been added to show the current position of execution.
Expected output:
start
in test_lambda
in Call
in lambda
Adding 5
total: 5
after first call
in test_lambda
in Call
in lambda
Adding 20
total: 25
after second call
in test_lambda
in Call
in lambda
Adding -256
total: -231
after third call
Actual output:
start
in test_lambda
in Call
after first call
in test_lambda
in Call
after second call
in test_lambda
in Call
after third call
^ permalink raw reply [flat|nested] 17+ messages in thread
* [Bug c++/54170] Call to lambda elided
2012-08-04 0:03 [Bug c++/54170] New: Call to lambda elided bekenn at yopmail dot com
` (4 preceding siblings ...)
2012-08-06 4:44 ` bekenn at yopmail dot com
@ 2012-08-06 4:46 ` bekenn at yopmail dot com
2012-08-06 7:52 ` redi at gcc dot gnu.org
` (9 subsequent siblings)
15 siblings, 0 replies; 17+ messages in thread
From: bekenn at yopmail dot com @ 2012-08-06 4:46 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54170
bekenn at yopmail dot com changed:
What |Removed |Added
----------------------------------------------------------------------------
Attachment #27935|0 |1
is obsolete| |
--- Comment #6 from bekenn at yopmail dot com 2012-08-06 04:46:01 UTC ---
Created attachment 27949
--> http://gcc.gnu.org/bugzilla/attachment.cgi?id=27949
preprocessed source for new example
^ permalink raw reply [flat|nested] 17+ messages in thread
* [Bug c++/54170] Call to lambda elided
2012-08-04 0:03 [Bug c++/54170] New: Call to lambda elided bekenn at yopmail dot com
` (5 preceding siblings ...)
2012-08-06 4:46 ` bekenn at yopmail dot com
@ 2012-08-06 7:52 ` redi at gcc dot gnu.org
2012-08-06 8:11 ` bekenn at yopmail dot com
` (8 subsequent siblings)
15 siblings, 0 replies; 17+ messages in thread
From: redi at gcc dot gnu.org @ 2012-08-06 7:52 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54170
Jonathan Wakely <redi at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|WAITING |NEW
CC| |jason at gcc dot gnu.org
--- Comment #7 from Jonathan Wakely <redi at gcc dot gnu.org> 2012-08-06 07:51:48 UTC ---
hmm, it still fails on trunk.
Jason, the fix for PR 52988 seems to be incomplete.
^ permalink raw reply [flat|nested] 17+ messages in thread
* [Bug c++/54170] Call to lambda elided
2012-08-04 0:03 [Bug c++/54170] New: Call to lambda elided bekenn at yopmail dot com
` (6 preceding siblings ...)
2012-08-06 7:52 ` redi at gcc dot gnu.org
@ 2012-08-06 8:11 ` bekenn at yopmail dot com
2012-08-06 8:32 ` redi at gcc dot gnu.org
` (7 subsequent siblings)
15 siblings, 0 replies; 17+ messages in thread
From: bekenn at yopmail dot com @ 2012-08-06 8:11 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54170
--- Comment #8 from bekenn at yopmail dot com 2012-08-06 08:11:38 UTC ---
(In reply to comment #4)
> If submitter can try current 4_7-branch or mainline, it would be easy for him
> to double check.
I installed mint in a virtual machine to test those, but I couldn't get either
trunk or gcc-4_7 to build; I got these errors, which I haven't bothered to
investigate:
build/gengtype.o: In function `create_optional_field_':
/home/bekenn/Projects/gcc-build/gcc/../../gcc-4_7/gcc/gengtype.c:853: undefined
reference to `lexer_line'
build/gengtype.o: In function `adjust_field_rtx_def':
/home/bekenn/Projects/gcc-build/gcc/../../gcc-4_7/gcc/gengtype.c:989: undefined
reference to `lexer_line'
/home/bekenn/Projects/gcc-build/gcc/../../gcc-4_7/gcc/gengtype.c:1045:
undefined reference to `lexer_line'
/home/bekenn/Projects/gcc-build/gcc/../../gcc-4_7/gcc/gengtype.c:1055:
undefined reference to `lexer_line'
/home/bekenn/Projects/gcc-build/gcc/../../gcc-4_7/gcc/gengtype.c:1121:
undefined reference to `lexer_line'
build/gengtype.o:/home/bekenn/Projects/gcc-build/gcc/../../gcc-4_7/gcc/gengtype.c:1160:
more undefined references to `lexer_line' follow
build/gengtype-parse.o: In function `token':
/home/bekenn/Projects/gcc-build/gcc/../../gcc-4_7/gcc/gengtype-parse.c:53:
undefined reference to `yylex'
build/gengtype-parse.o: In function `parse_error':
/home/bekenn/Projects/gcc-build/gcc/../../gcc-4_7/gcc/gengtype-parse.c:142:
undefined reference to `lexer_line'
/home/bekenn/Projects/gcc-build/gcc/../../gcc-4_7/gcc/gengtype-parse.c:142:
undefined reference to `lexer_line'
build/gengtype-parse.o: In function `struct_field_seq':
/home/bekenn/Projects/gcc-build/gcc/../../gcc-4_7/gcc/gengtype-parse.c:692:
undefined reference to `lexer_line'
build/gengtype-parse.o: In function `type':
/home/bekenn/Projects/gcc-build/gcc/../../gcc-4_7/gcc/gengtype-parse.c:726:
undefined reference to `lexer_line'
/home/bekenn/Projects/gcc-build/gcc/../../gcc-4_7/gcc/gengtype-parse.c:758:
undefined reference to `lexer_line'
build/gengtype-parse.o:/home/bekenn/Projects/gcc-build/gcc/../../gcc-4_7/gcc/gengtype-parse.c:758:
more undefined references to `lexer_line' follow
build/gengtype-parse.o: In function `parse_file':
/home/bekenn/Projects/gcc-build/gcc/../../gcc-4_7/gcc/gengtype-parse.c:951:
undefined reference to `yybegin'
/home/bekenn/Projects/gcc-build/gcc/../../gcc-4_7/gcc/gengtype-parse.c:986:
undefined reference to `lexer_toplevel_done'
/home/bekenn/Projects/gcc-build/gcc/../../gcc-4_7/gcc/gengtype-parse.c:991:
undefined reference to `yyend'
collect2: ld returned 1 exit status
^ permalink raw reply [flat|nested] 17+ messages in thread
* [Bug c++/54170] Call to lambda elided
2012-08-04 0:03 [Bug c++/54170] New: Call to lambda elided bekenn at yopmail dot com
` (7 preceding siblings ...)
2012-08-06 8:11 ` bekenn at yopmail dot com
@ 2012-08-06 8:32 ` redi at gcc dot gnu.org
2012-11-30 12:31 ` paolo.carlini at oracle dot com
` (6 subsequent siblings)
15 siblings, 0 replies; 17+ messages in thread
From: redi at gcc dot gnu.org @ 2012-08-06 8:32 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54170
--- Comment #9 from Jonathan Wakely <redi at gcc dot gnu.org> 2012-08-06 08:32:28 UTC ---
I think those errors indicate you don't have Flex installed
^ permalink raw reply [flat|nested] 17+ messages in thread
* [Bug c++/54170] Call to lambda elided
2012-08-04 0:03 [Bug c++/54170] New: Call to lambda elided bekenn at yopmail dot com
` (8 preceding siblings ...)
2012-08-06 8:32 ` redi at gcc dot gnu.org
@ 2012-11-30 12:31 ` paolo.carlini at oracle dot com
2012-12-03 16:02 ` paolo at gcc dot gnu.org
` (5 subsequent siblings)
15 siblings, 0 replies; 17+ messages in thread
From: paolo.carlini at oracle dot com @ 2012-11-30 12:31 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54170
Paolo Carlini <paolo.carlini at oracle dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |ASSIGNED
AssignedTo|unassigned at gcc dot |paolo.carlini at oracle dot
|gnu.org |com
--- Comment #10 from Paolo Carlini <paolo.carlini at oracle dot com> 2012-11-30 12:31:15 UTC ---
It is really an incomplete fix for PR52988, changing nullptr to (void*)0 works
around the problem. Looking a bit into it.
^ permalink raw reply [flat|nested] 17+ messages in thread
* [Bug c++/54170] Call to lambda elided
2012-08-04 0:03 [Bug c++/54170] New: Call to lambda elided bekenn at yopmail dot com
` (9 preceding siblings ...)
2012-11-30 12:31 ` paolo.carlini at oracle dot com
@ 2012-12-03 16:02 ` paolo at gcc dot gnu.org
2012-12-03 16:10 ` paolo.carlini at oracle dot com
` (4 subsequent siblings)
15 siblings, 0 replies; 17+ messages in thread
From: paolo at gcc dot gnu.org @ 2012-12-03 16:02 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54170
--- Comment #11 from paolo at gcc dot gnu.org <paolo at gcc dot gnu.org> 2012-12-03 16:01:43 UTC ---
Author: paolo
Date: Mon Dec 3 16:01:32 2012
New Revision: 194098
URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=194098
Log:
/cp
2012-12-03 Paolo Carlini <paolo.carlini@oracle.com>
PR c++/54170
* cvt.c (cp_convert_to_pointer): Don't discard side-effects from
expressions of nullptr_t.
* typeck.c (build_ptrmemfunc): Likewise.
/testsuite
2012-12-03 Paolo Carlini <paolo.carlini@oracle.com>
PR c++/54170
* g++.dg/cpp0x/lambda/lambda-nullptr.C: New.
Added:
trunk/gcc/testsuite/g++.dg/cpp0x/lambda/lambda-nullptr.C
Modified:
trunk/gcc/cp/ChangeLog
trunk/gcc/cp/cvt.c
trunk/gcc/cp/typeck.c
trunk/gcc/testsuite/ChangeLog
^ permalink raw reply [flat|nested] 17+ messages in thread
* [Bug c++/54170] Call to lambda elided
2012-08-04 0:03 [Bug c++/54170] New: Call to lambda elided bekenn at yopmail dot com
` (10 preceding siblings ...)
2012-12-03 16:02 ` paolo at gcc dot gnu.org
@ 2012-12-03 16:10 ` paolo.carlini at oracle dot com
2013-07-10 2:57 ` foom at fuhm dot net
` (3 subsequent siblings)
15 siblings, 0 replies; 17+ messages in thread
From: paolo.carlini at oracle dot com @ 2012-12-03 16:10 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54170
Paolo Carlini <paolo.carlini at oracle dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|ASSIGNED |RESOLVED
Resolution| |FIXED
Target Milestone|--- |4.8.0
--- Comment #12 from Paolo Carlini <paolo.carlini at oracle dot com> 2012-12-03 16:10:13 UTC ---
Fixed for 4.8.0.
^ permalink raw reply [flat|nested] 17+ messages in thread
* [Bug c++/54170] Call to lambda elided
2012-08-04 0:03 [Bug c++/54170] New: Call to lambda elided bekenn at yopmail dot com
` (11 preceding siblings ...)
2012-12-03 16:10 ` paolo.carlini at oracle dot com
@ 2013-07-10 2:57 ` foom at fuhm dot net
2013-07-10 5:14 ` jason at gcc dot gnu.org
` (2 subsequent siblings)
15 siblings, 0 replies; 17+ messages in thread
From: foom at fuhm dot net @ 2013-07-10 2:57 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54170
James Y Knight <foom at fuhm dot net> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |foom at fuhm dot net
--- Comment #13 from James Y Knight <foom at fuhm dot net> ---
Possibly should be backported to 4.7 branch?
^ permalink raw reply [flat|nested] 17+ messages in thread
* [Bug c++/54170] Call to lambda elided
2012-08-04 0:03 [Bug c++/54170] New: Call to lambda elided bekenn at yopmail dot com
` (12 preceding siblings ...)
2013-07-10 2:57 ` foom at fuhm dot net
@ 2013-07-10 5:14 ` jason at gcc dot gnu.org
2013-07-10 5:54 ` jason at gcc dot gnu.org
2014-05-24 12:11 ` redi at gcc dot gnu.org
15 siblings, 0 replies; 17+ messages in thread
From: jason at gcc dot gnu.org @ 2013-07-10 5:14 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54170
--- Comment #14 from Jason Merrill <jason at gcc dot gnu.org> ---
The patch does seem safe enough for 4.7, even though I usually prefer not to
backport C++11 fixes to older release series.
^ permalink raw reply [flat|nested] 17+ messages in thread
* [Bug c++/54170] Call to lambda elided
2012-08-04 0:03 [Bug c++/54170] New: Call to lambda elided bekenn at yopmail dot com
` (13 preceding siblings ...)
2013-07-10 5:14 ` jason at gcc dot gnu.org
@ 2013-07-10 5:54 ` jason at gcc dot gnu.org
2014-05-24 12:11 ` redi at gcc dot gnu.org
15 siblings, 0 replies; 17+ messages in thread
From: jason at gcc dot gnu.org @ 2013-07-10 5:54 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54170
Jason Merrill <jason at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Target Milestone|4.8.0 |4.7.4
--- Comment #15 from Jason Merrill <jason at gcc dot gnu.org> ---
Fixed for 4.7.4.
^ permalink raw reply [flat|nested] 17+ messages in thread
* [Bug c++/54170] Call to lambda elided
2012-08-04 0:03 [Bug c++/54170] New: Call to lambda elided bekenn at yopmail dot com
` (14 preceding siblings ...)
2013-07-10 5:54 ` jason at gcc dot gnu.org
@ 2014-05-24 12:11 ` redi at gcc dot gnu.org
15 siblings, 0 replies; 17+ messages in thread
From: redi at gcc dot gnu.org @ 2014-05-24 12:11 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=54170
Jonathan Wakely <redi at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |fox at ucw dot cz
--- Comment #16 from Jonathan Wakely <redi at gcc dot gnu.org> ---
*** Bug 61302 has been marked as a duplicate of this bug. ***
^ permalink raw reply [flat|nested] 17+ messages in thread