------- Comment #1 from jakub at gcc dot gnu dot org 2009-06-08 16:26 ------- Subject: Bug 40370
Author: jakub Date: Mon Jun 8 16:26:01 2009 New Revision: 148278 URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=148278 Log: PR c++/40370 PR c++/40372 * parser.c (cp_parser_direct_declarator): Don't set TREE_SIDE_EFFECTS on error_mark_node. Check for VLAs outside of function context before check whether to wrap bounds into a NOP_EXPR with TREE_SIDE_EFFECTS. * g++.dg/template/error41.C: New test. * g++.dg/template/error42.C: New test. Added: trunk/gcc/testsuite/g++.dg/template/error41.C trunk/gcc/testsuite/g++.dg/template/error42.C Modified: trunk/gcc/cp/ChangeLog trunk/gcc/cp/parser.c trunk/gcc/testsuite/ChangeLog -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40370