[Bug c++/56239] [4.6/4.7 Regression] parse error calling operator() on parenthesized value-initialized temporary
jakub at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Tue Feb 19 17:23:00 GMT 2013
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=56239
--- Comment #7 from Jakub Jelinek <jakub at gcc dot gnu.org> 2013-02-19 17:22:51 UTC ---
Author: jakub
Date: Tue Feb 19 17:22:43 2013
New Revision: 196145
URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=196145
Log:
Backported from mainline
2013-02-07 Jakub Jelinek <jakub@redhat.com>
PR c++/56239
* parser.c (cp_parser_token_starts_cast_expression): Renamed to...
(cp_parser_tokens_start_cast_expression): ... this. Change parameter
to cp_parser *, call cp_lexer_peek_token first. For CPP_OPEN_PAREN,
return true only if 2nd token isn't CPP_CLOSE_PAREN.
(cp_parser_cast_expression): Adjust caller.
* g++.dg/parse/pr56239.C: New test.
Added:
branches/gcc-4_7-branch/gcc/testsuite/g++.dg/parse/pr56239.C
Modified:
branches/gcc-4_7-branch/gcc/cp/ChangeLog
branches/gcc-4_7-branch/gcc/cp/parser.c
branches/gcc-4_7-branch/gcc/testsuite/ChangeLog
More information about the Gcc-bugs
mailing list