From: Richard Stallman Date: Thu, 10 Sep 1992 05:33:47 +0000 (+0000) Subject: (declare_function_name): Allow for anonymous function. X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=6152f87688139edd35e573d3fc304f05aea10766;p=gcc.git (declare_function_name): Allow for anonymous function. From-SVN: r2095 --- diff --git a/gcc/c-common.c b/gcc/c-common.c index f647b40539f..bf761106fa0 100644 --- a/gcc/c-common.c +++ b/gcc/c-common.c @@ -42,7 +42,11 @@ declare_function_name () char *kind = "function"; if (TREE_CODE (TREE_TYPE (current_function_decl)) == METHOD_TYPE) kind = "method"; - name = IDENTIFIER_POINTER (DECL_NAME (current_function_decl)); + /* Allow functions to be nameless (such as artificial ones). */ + if (DECL_NAME (current_function_decl)) + name = IDENTIFIER_POINTER (DECL_NAME (current_function_decl)); + else + name = ""; printable_name = (*decl_printable_name) (current_function_decl, &kind); }