From: Jakub Jelinek Date: Mon, 7 Dec 2015 22:44:19 +0000 (+0100) Subject: re PR c++/68760 (ICE in pp_string (pretty-print.c:909)) X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=7c010e27a9e9d975ff265264ae515f7dc9feebd6;p=gcc.git re PR c++/68760 (ICE in pp_string (pretty-print.c:909)) PR c++/68760 * error.c (dump_global_iord): Use DECL_SOURCE_FILE (t) instead of LOCATION_FILE (input_location). * g++.dg/tree-ssa/pr68760.C: New test. From-SVN: r231386 --- diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog index 6b007e2aea3..7569a625a7c 100644 --- a/gcc/cp/ChangeLog +++ b/gcc/cp/ChangeLog @@ -1,3 +1,9 @@ +2015-12-07 Jakub Jelinek + + PR c++/68760 + * error.c (dump_global_iord): Use DECL_SOURCE_FILE (t) + instead of LOCATION_FILE (input_location). + 2015-12-07 Ryan Burn PR c++/68683 diff --git a/gcc/cp/error.c b/gcc/cp/error.c index 38548c72fe0..e0ba806b32d 100644 --- a/gcc/cp/error.c +++ b/gcc/cp/error.c @@ -953,7 +953,7 @@ dump_global_iord (cxx_pretty_printer *pp, tree t) else gcc_unreachable (); - pp_printf (pp, p, LOCATION_FILE (input_location)); + pp_printf (pp, p, DECL_SOURCE_FILE (t)); } static void diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index 48cc7aebfae..000165ce0f9 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,5 +1,8 @@ 2015-12-07 Jakub Jelinek + PR c++/68760 + * g++.dg/tree-ssa/pr68760.C: New test. + PR middle-end/66726 * g++.dg/tree-ssa/pr66726.c: Renamed to... * g++.dg/tree-ssa/pr66726.C: ... this. diff --git a/gcc/testsuite/g++.dg/tree-ssa/pr68760.C b/gcc/testsuite/g++.dg/tree-ssa/pr68760.C new file mode 100644 index 00000000000..a22b88ea483 --- /dev/null +++ b/gcc/testsuite/g++.dg/tree-ssa/pr68760.C @@ -0,0 +1,5 @@ +// PR c++/68760 +// { dg-do compile } +// { dg-options "-fdump-ipa-cgraph" } + +struct A { A (); } a;