]> gcc.gnu.org Git - gcc.git/commitdiff
re PR c++/41503 (function_parameter_expanded_from_pack_p segfaults when passed a...
authorMartin Jambor <mjambor@suse.cz>
Thu, 1 Oct 2009 09:31:08 +0000 (11:31 +0200)
committerMartin Jambor <jamborm@gcc.gnu.org>
Thu, 1 Oct 2009 09:31:08 +0000 (11:31 +0200)
2009-10-01  Martin Jambor  <mjambor@suse.cz>

PR c++/41503
* cp/pt.c (function_parameter_expanded_from_pack_p): Return false if
DECL_ARTIFICIAL (param_decl) is true.

From-SVN: r152365

gcc/ChangeLog
gcc/cp/pt.c

index e80433ae8b8668d83754facf29d9785f842a514b..78f6a6ea9abbd587a4f86dc032755bd4197b56ea 100644 (file)
@@ -1,3 +1,9 @@
+2009-10-01  Martin Jambor  <mjambor@suse.cz>
+
+       PR c++/41503
+       * cp/pt.c (function_parameter_expanded_from_pack_p): Return false if
+       DECL_ARTIFICIAL (param_decl) is true.
+       
 2009-09-30  Gabriel Dos Reis  <gdr@cs.tamu.edu>
 
        * tree.h (tree_decl_common::lang_flag_8): New.
index d078642226bfaf268ab0a0870667bf1b1d63355d..5f9b07cde73bb7af7448ade1e327667e2ebdece8 100644 (file)
@@ -2669,7 +2669,8 @@ get_function_template_decl (const_tree primary_func_tmpl_inst)
 bool
 function_parameter_expanded_from_pack_p (tree param_decl, tree pack)
 {
-    if (! function_parameter_pack_p (pack))
+    if (DECL_ARTIFICIAL (param_decl)
+       || !function_parameter_pack_p (pack))
       return false;
 
     gcc_assert (DECL_NAME (param_decl) && DECL_NAME (pack));
This page took 0.122664 seconds and 5 git commands to generate.