This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: macro debugging info: always include space after macro name
- From: Neil Booth <neil at daikokuya dot demon dot co dot uk>
- To: Jim Blandy <jimb at redhat dot com>
- Cc: gcc-patches at gcc dot gnu dot org
- Date: Mon, 18 Mar 2002 23:29:38 +0000
- Subject: Re: macro debugging info: always include space after macro name
- References: <npsn6xwk2v.fsf@zwingli.cygnus.com>
Jim Blandy wrote:-
> I'm not sure the patch below is the best fix, for several reasons:
>
> - Shouldn't meeting picayune requirements of the Dwarf format be
> handled in dwarf2out? (Although, in the absence of guarantees from
> the caller, that code would have to scan each definition to see
> whether it needed an extra space...)
>
> - Shouldn't the Dwarf spec be relaxed to allow generators to omit the
> space when the macro's replacement list is empty? (Although this is
> the kind of minor variation that is appropriate for user input, but
> not so welcome in machine-readable formats...)
>
> - If the `define' member of `struct gcc_debug_hooks' really requires
> that its `text' argument be in strict Dwarf 2 form, shouldn't that
> be documented?
Jim,
Your patch is fine. Well spotted. I don't think we care about trailing
spaces in -dD output, and we may as well match the dwarf spec.
It's good for 3.2, and 3.1 too I guess if we want the next released GCC
to be OK with GDB.
Neil.