Use dump_function_name rather than emit <built-in>
authorMartin Jambor <mjambor@suse.cz>
Wed, 7 Dec 2016 13:09:07 +0000 (14:09 +0100)
committerMartin Jambor <jamborm@gcc.gnu.org>
Wed, 7 Dec 2016 13:09:07 +0000 (14:09 +0100)
2016-12-07  Martin Jambor  <mjambor@suse.cz>

PR c++/78589
* error.c (dump_decl): Use dump_function_name to dump
!DECL_LANG_SPECIFIC function decls with no or self-referencing
abstract origin.

From-SVN: r243344

gcc/cp/ChangeLog
gcc/cp/error.c

index c666f1689652fe5a2553330639cff7cb36800b44..a59d25b7caad407c3c63e3208c23ddfeeaaaaa44 100644 (file)
@@ -1,3 +1,10 @@
+2016-12-07  Martin Jambor  <mjambor@suse.cz>
+
+       PR c++/78589
+       * error.c (dump_decl): Use dump_function_name to dump
+       !DECL_LANG_SPECIFIC function decls with no or self-referencing
+       abstract origin.
+
 2016-12-07  Nathan Sidwell  <nathan@acm.org>
 
        * pt.c (tsubst <{NON,}TYPE_ARGUMENT_PACK>: Simplify control flow
index 7bf07c341622103b9752955e41d4306fd9cb1410..5f8fb2a1838da80d3cf986c30a4cb33c57d96ca8 100644 (file)
@@ -1216,10 +1216,11 @@ dump_decl (cxx_pretty_printer *pp, tree t, int flags)
     case FUNCTION_DECL:
       if (! DECL_LANG_SPECIFIC (t))
        {
-         if (DECL_ABSTRACT_ORIGIN (t))
+         if (DECL_ABSTRACT_ORIGIN (t)
+             && DECL_ABSTRACT_ORIGIN (t) != t)
            dump_decl (pp, DECL_ABSTRACT_ORIGIN (t), flags);
          else
-           pp_string (pp, M_("<built-in>"));
+           dump_function_name (pp, t, flags);
        }
       else if (DECL_GLOBAL_CTOR_P (t) || DECL_GLOBAL_DTOR_P (t))
        dump_global_iord (pp, t);