OSDN Git Service

/cp
authorpaolo <paolo@138bc75d-0d04-0410-961f-82ee72b054a4>
Tue, 4 May 2010 14:17:52 +0000 (14:17 +0000)
committerMasaki Muranaka <monaka@monami-software.com>
Sun, 23 May 2010 04:58:34 +0000 (13:58 +0900)
2010-05-04  Paolo Carlini  <paolo.carlini@oracle.com>

PR c++/43705
* call.c (build_new_method_call): Return error_mark_node if fns is
NULL_TREE.

/testsuite
2010-05-04  Paolo Carlini  <paolo.carlini@oracle.com>

PR c++/43705
* g++.dg/template/crash95.C: New.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@159029 138bc75d-0d04-0410-961f-82ee72b054a4

gcc/cp/ChangeLog
gcc/cp/call.c
gcc/testsuite/ChangeLog
gcc/testsuite/g++.dg/template/crash95.C

index 026abe8..634a74b 100644 (file)
@@ -1,3 +1,9 @@
+2010-05-04  Paolo Carlini  <paolo.carlini@oracle.com>
+
+       PR c++/43705
+       * call.c (build_new_method_call): Return error_mark_node if fns is
+       NULL_TREE.
+
 2010-05-03  Dodji Seketeli  <dodji@redhat.com>
 
        PR c++/43953
index 7915417..157b473 100644 (file)
@@ -6219,7 +6219,7 @@ build_new_method_call (tree instance, tree fns, VEC(tree,gc) **args,
     *fn_p = NULL_TREE;
 
   if (error_operand_p (instance)
-      || error_operand_p (fns))
+      || !fns || error_operand_p (fns))
     return error_mark_node;
 
   if (!BASELINK_P (fns))
index 29eaf71..d43de64 100644 (file)
@@ -1,3 +1,8 @@
+2010-05-04  Paolo Carlini  <paolo.carlini@oracle.com>
+
+       PR c++/43705
+       * g++.dg/template/crash95.C: New.
+
 2010-05-04  H.J. Lu  <hongjiu.lu@intel.com>
 
        PR debug/43508
index 2ad9e98..959a9d0 100644 (file)
@@ -8,4 +8,4 @@ template < typename > struct S
   };
 };
 
-S < int > s(0); // { dg-error "incomplete type" }
+S < int > s(0);