With the C++14 constexpr support we were getting confused by using finish_expr_stmt on something that isn't an expression. This already should have been add_stmt, so I'm checking it in separately.

Tested x86_64-pc-linux-gnu, applying to trunk.
commit 046fdf7db65830bc1030d766ffa8f4ba696e0660
Author: Jason Merrill <ja...@redhat.com>
Date:   Sat Nov 15 01:31:47 2014 -0500

    	* parser.c (cp_parser_omp_declare_reduction_exprs): A block is not
    	an expression.

diff --git a/gcc/cp/parser.c b/gcc/cp/parser.c
index 3ab65a9..111ec10 100644
--- a/gcc/cp/parser.c
+++ b/gcc/cp/parser.c
@@ -31188,7 +31188,7 @@ cp_parser_omp_declare_reduction_exprs (tree fndecl, cp_parser *parser)
 
       block = finish_omp_structured_block (block);
       cp_walk_tree (&block, cp_remove_omp_priv_cleanup_stmt, omp_priv, NULL);
-      finish_expr_stmt (block);
+      add_stmt (block);
 
       if (ctor)
 	add_decl_expr (omp_orig);

Reply via email to