]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
re PR c++/38357 (ICE cc1plus (Segmentation fault))
authorSteve Ellcey <sje@cup.hp.com>
Thu, 15 Jan 2009 18:07:46 +0000 (18:07 +0000)
committerSteve Ellcey <sje@gcc.gnu.org>
Thu, 15 Jan 2009 18:07:46 +0000 (18:07 +0000)
PR c++/38357
* pt.c (tsubst): Check for NULL args.

From-SVN: r143402

gcc/cp/ChangeLog
gcc/cp/pt.c

index 07b9c7e49e6d09a5d8232d224a7ed03f64cd6e3e..af7f0c06b9e30a1fbc5496978c9cfb98c360a0df 100644 (file)
@@ -1,3 +1,8 @@
+2009-01-15  Steve Ellcey  <sje@cup.hp.com>
+
+       PR c++/38357
+       * pt.c (tsubst): Check for NULL args.
+
 2009-01-15  Dodji Seketeli  <dodji@redhat.com>
 
        PR c++/38636
index de70e531d0be678f8a5b9c130e797dc52ee47cec..0618fe2432876f74d7733c4bfa4705f9e50b0102 100644 (file)
@@ -8975,6 +8975,9 @@ tsubst (tree t, tree args, tsubst_flags_t complain, tree in_decl)
   if (DECL_P (t))
     return tsubst_decl (t, args, complain);
 
+  if (args == NULL_TREE)
+    return t;
+
   if (TREE_CODE (t) == IDENTIFIER_NODE)
     type = IDENTIFIER_TYPE_VALUE (t);
   else