summaryrefslogtreecommitdiff
path: root/gcc/langhooks.c
diff options
context:
space:
mode:
authorsteven <steven@138bc75d-0d04-0410-961f-82ee72b054a4>2004-09-11 19:48:58 +0000
committersteven <steven@138bc75d-0d04-0410-961f-82ee72b054a4>2004-09-11 19:48:58 +0000
commita1080ab2d44eb7cb0dac6b2d6a54ecbc632a0646 (patch)
treebb1962bfc50766eb7a19c562763e5c166da579bc /gcc/langhooks.c
parenta0f68376397a4e73894da71deef9ab085269da45 (diff)
downloadgcc-a1080ab2d44eb7cb0dac6b2d6a54ecbc632a0646.tar.gz
PR c++/17412
* fold-const.c (fold): Do not try to fold the operand of a CLEANUP_POINT_EXPR if that operand does itself not have any operands. testsuite/ * g++.dg/parse/break-in-for.C: New test. PR middle-end/17417 * langhooks.c (lhd_decl_printable_name): Make sure that this function is called with is a decl node that has an identifier. * tree-pretty-print.c (dump_function_name): New function to wrap PRINT_FUNCTION_NAME and dump_decl_name. (print_call_name): Use it. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@87363 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/langhooks.c')
-rw-r--r--gcc/langhooks.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/gcc/langhooks.c b/gcc/langhooks.c
index 9f0a236e8d3..309bef57794 100644
--- a/gcc/langhooks.c
+++ b/gcc/langhooks.c
@@ -267,6 +267,7 @@ lhd_expand_decl (tree ARG_UNUSED (t))
const char *
lhd_decl_printable_name (tree decl, int ARG_UNUSED (verbosity))
{
+ gcc_assert (decl && DECL_NAME (decl));
return IDENTIFIER_POINTER (DECL_NAME (decl));
}