On 05/20/14 08:10, Zamyatin, Igor wrote:
Please look then on the following patch.
Regtested successfully on x86_64.
Is it ok for trunk and 4.9?
gcc/cp/ChangeLog:
2014-05-20 Igor Zamyatin
PR c/60189
* parser.c (cp_parser_postfix_expression): Move handling of cilk_sync
from here to...
(cp_pa
n 0;
+}
Thanks,
Igor
> -Original Message-
> From: Zamyatin, Igor
> Sent: Tuesday, May 13, 2014 12:28 AM
> To: 'Jason Merrill'; 'Jakub Jelinek'
> Cc: 'GCC Patches (gcc-patches@gcc.gnu.org)'; Iyer, Balaji V
> Subject: RE: [PATCH, PR60189, Cil
laji V
> > Subject: Re: [PATCH, PR60189, Cilk+] Fix for ICE with incorrect
> > Cilk_sync usage
> >
> > Oh, I see where the problem is coming from. Cilk_sync is a statement,
> > but it's being parsed as an expression. Let's move it to
> cp_parser_statem
> > From: Jason Merrill [mailto:ja...@redhat.com]
> > Sent: Monday, April 14, 2014 9:49 PM
> > To: Zamyatin, Igor; Jakub Jelinek
> > Cc: GCC Patches (gcc-patches@gcc.gnu.org); Iyer, Balaji V
> > Subject: Re: [PATCH, PR60189, Cilk+] Fix for ICE with incorrect
> &g
> -Original Message-
> From: Jason Merrill [mailto:ja...@redhat.com]
> Sent: Monday, April 14, 2014 9:49 PM
> To: Zamyatin, Igor; Jakub Jelinek
> Cc: GCC Patches (gcc-patches@gcc.gnu.org); Iyer, Balaji V
> Subject: Re: [PATCH, PR60189, Cilk+] Fix for ICE with incorrect
Oh, I see where the problem is coming from. Cilk_sync is a statement,
but it's being parsed as an expression. Let's move it to
cp_parser_statement.
Jason
> -Original Message-
> From: Jason Merrill [mailto:ja...@redhat.com]
> Sent: Monday, April 14, 2014 8:13 AM
> To: Zamyatin, Igor; Jakub Jelinek
> Cc: GCC Patches (gcc-patches@gcc.gnu.org); Iyer, Balaji V
> Subject: Re: [PATCH, PR60189, Cilk+] Fix for ICE with incorrect
On 04/11/2014 03:08 PM, Zamyatin, Igor wrote:
I remembered - I haven't used cp_parser_require since it calls
cp_lexer_consume_token which is not needed at this point. It is already called
a bit earlier.
So the call to cp_parser_require can replace that call as well.
Jason
>
> >> + token = cp_lexer_peek_token (parser->lexer);
> >> + if (token->type != CPP_SEMICOLON)
> >> + {
> >> + error_at (token->location, "%<_Cilk_sync%> must be
> >> followed"
> >> + " by semicolon");
> >> + post
>
> >> + token = cp_lexer_peek_token (parser->lexer);
> >> + if (token->type != CPP_SEMICOLON)
> >> + {
> >> + error_at (token->location, "%<_Cilk_sync%> must be
> >> followed"
> >> + " by semicolon");
> >> + post
On 04/10/2014 10:27 AM, Jakub Jelinek wrote:
I don't see the point of adding the extra {} around the whole case,
there is no variable declared at that point.
Agreed.
+ token = cp_lexer_peek_token (parser->lexer);
+ if (token->type != CPP_SEMICOLON)
+ {
+
On Thu, Apr 10, 2014 at 02:23:16PM +, Zamyatin, Igor wrote:
> 2014-04-10 Igor Zamyatin
>
> PR c++/60189
> * parser.c (cp_parser_postfix_expression): Make sure only
> semicolon can go after Cilk_sync.
>
> gcc/testsuite/ChangeLog:
>
> 2014-04-10 Igor Zamyatin
>
> PR c++/60189
> * c-c++-
Resending with correct Changelog
Is it OK?
Thanks,
Igor
gcc/cp/ChangeLog:
2014-04-10 Igor Zamyatin
PR c++/60189
* parser.c (cp_parser_postfix_expression): Make sure only
semicolon can go after Cilk_sync.
gcc/testsuite/ChangeLog:
2014-04-10 Igor Zamyatin
PR c++/60189
* c-c++-common/cil
13 matches
Mail list logo