https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71147
--- Comment #5 from Martin Sebor <msebor at gcc dot gnu.org> --- Author: msebor Date: Tue May 24 20:29:36 2016 New Revision: 236664 URL: https://gcc.gnu.org/viewcvs?rev=236664&root=gcc&view=rev Log: PR c++/71147 - [6 Regression] Flexible array member wrongly rejected in template gcc/ChangeLog: 2016-05-24 Martin Sebor <mse...@redhat.com> PR c++/71147 * gcc/tree.h (complete_or_array_type_p): New inline function. gcc/testsuite/ChangeLog: 2016-05-24 Martin Sebor <mse...@redhat.com> PR c++/71147 * g++.dg/ext/flexary16.C: New test. gcc/cp/ChangeLog: 2016-05-24 Martin Sebor <mse...@redhat.com> PR c++/71147 * decl.c (layout_var_decl, grokdeclarator): Use complete_or_array_type_p. * pt.c (instantiate_class_template_1): Try to complete the element type of a flexible array member. (can_complete_type_without_circularity): Handle arrays of unknown bound. * typeck.c (complete_type): Also complete the type of the elements of arrays with an unspecified bound. Added: trunk/gcc/testsuite/g++.dg/ext/flexary16.C Modified: trunk/gcc/ChangeLog trunk/gcc/cp/ChangeLog trunk/gcc/cp/decl.c trunk/gcc/cp/pt.c trunk/gcc/cp/typeck.c trunk/gcc/testsuite/ChangeLog trunk/gcc/tree.h