We reject extended statement-expressions in template parameters, so we
might as well reject them in constant expressions used in noexcept
specifications.
for  gcc/cp/ChangeLog
	PR c++/84968
	* tree.c (strip_typedefs_expr): Reject STATEMENT_LISTs.
for  gcc/testsuite/ChangeLog
	PR c++/84968
	* g++.dg/eh/pr84968.C: New.
From-SVN: r258913
+2018-03-28  Alexandre Oliva <aoliva@redhat.com>
+
+       PR c++/84968
+       * tree.c (strip_typedefs_expr): Reject STATEMENT_LISTs.
+
 2018-03-27  Paolo Carlini  <paolo.carlini@oracle.com>
 
        PR c++/85067
 
       error ("lambda-expression in a constant expression");
       return error_mark_node;
 
+    case STATEMENT_LIST:
+      error ("statement-expression in a constant expression");
+      return error_mark_node;
+
     default:
       break;
     }
 
+2018-03-28  Alexandre Oliva <aoliva@redhat.com>
+
+       PR c++/84968
+       * g++.dg/eh/pr84968.C: New.
+
 2018-03-27  Michael Meissner  <meissner@linux.vnet.ibm.com>
 
        PR target/84914
 
--- /dev/null
+// { dg-do compile { target c++11 } }
+
+// { dg-options "" }
+
+union b;
+
+struct S {
+  template <typename>
+  void a()
+    try {
+    } catch (int ()
+            noexcept (({ union b a; true; }))) // { dg-error "constant" }
+  {
+  }
+};