]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
re PR c++/58835 (ICE with __PRETTY_FUNCTION__ in broken function)
authorKai Tietz <ktietz@redhat.com>
Thu, 20 Feb 2014 14:29:55 +0000 (15:29 +0100)
committerKai Tietz <ktietz@gcc.gnu.org>
Thu, 20 Feb 2014 14:29:55 +0000 (15:29 +0100)
PR c++/58835
* semantics.c (finish_fname): Handle error_mark_node.

From-SVN: r207956

gcc/cp/ChangeLog
gcc/cp/semantics.c

index 6fdfb7fce0cfb45c9eabdd515c743a43747e60ff..6b04f4ccbbdf947846523f9882432936e76b3461 100644 (file)
@@ -1,3 +1,8 @@
+2014-02-20  Kai Tietz  <ktietz@redhat.com>
+
+       PR c++/58835
+       * semantics.c (finish_fname): Handle error_mark_node.
+
 2014-02-19  Jason Merrill  <jason@redhat.com>
 
        PR c++/60046
index 16b50e0969808323ab0504e65aed5cc663d7593a..8a63036e516b8088a326e5e010a6921469f06d14 100644 (file)
@@ -2501,7 +2501,8 @@ finish_fname (tree id)
   tree decl;
 
   decl = fname_decl (input_location, C_RID_CODE (id), id);
-  if (processing_template_decl && current_function_decl)
+  if (processing_template_decl && current_function_decl
+      && decl != error_mark_node)
     decl = DECL_NAME (decl);
   return decl;
 }