This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [vta,vta4.3,trunk?] don't compute DECL_ASSEMBLER_NAME because of debugging dumps
- From: Ian Lance Taylor <iant at google dot com>
- To: Alexandre Oliva <aoliva at redhat dot com>
- Cc: gcc-patches at gcc dot gnu dot org
- Date: Wed, 17 Sep 2008 08:23:46 -0700
- Subject: Re: [vta,vta4.3,trunk?] don't compute DECL_ASSEMBLER_NAME because of debugging dumps
- References: <ortzcni3na.fsf@oliva.athome.lsd.ic.unicamp.br>
Alexandre Oliva <aoliva@redhat.com> writes:
> fprintf (dump_orig, " (%s)\n",
> - IDENTIFIER_POINTER (DECL_ASSEMBLER_NAME (fndecl)));
> + !DECL_ASSEMBLER_NAME_SET_P (fndecl) ? NULL
> + : IDENTIFIER_POINTER (DECL_ASSEMBLER_NAME (fndecl)));
Don't pass NULL to fprintf for a %s argument.
Use parentheses around the multi-line ternary expression.
A patch to pass "null", or similar, instead is OK.
Thanks.
Ian