This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH 4/5] add gcc/gdb interface files
- From: Jakub Jelinek <jakub at redhat dot com>
- To: Tom Tromey <tromey at redhat dot com>
- Cc: Jeff Law <law at redhat dot com>, gcc-patches at gcc dot gnu dot org
- Date: Fri, 6 Jun 2014 07:35:24 +0200
- Subject: Re: [PATCH 4/5] add gcc/gdb interface files
- Authentication-results: sourceware.org; auth=none
- References: <1400254001-12038-1-git-send-email-tromey at redhat dot com> <1400254001-12038-5-git-send-email-tromey at redhat dot com> <537DF2F5 dot 4030009 at redhat dot com> <20140522131635 dot GE10386 at tucnak dot redhat dot com> <874n009zpa dot fsf at fleche dot redhat dot com> <5390C3B9 dot 5090807 at redhat dot com> <20140605193039 dot GI10386 at tucnak dot redhat dot com> <87a99q6bvt dot fsf at fleche dot redhat dot com>
- Reply-to: Jakub Jelinek <jakub at redhat dot com>
On Thu, Jun 05, 2014 at 07:54:30PM -0600, Tom Tromey wrote:
> >>>>> "Jakub" == Jakub Jelinek <jakub@redhat.com> writes:
>
> Jakub> Another possibility would be to give the macros twice as many arguments
> Jakub> as there are parameters and just through the odd arguments away when
> Jakub> expanding to the template parameters. That would mean you write
> Jakub> GCC_METHOD7 (gcc_decl, build_decl,
> Jakub> const char *, name,
> Jakub> enum gcc_c_symbol_kind, sym_kind,
> Jakub> const char *, substitution_name,
> Jakub> gcc_address, address,
> Jakub> const char *, filename,
> Jakub> unsigned int, line_number);
> Jakub> though it isn't very nice either, guess I'm bikeshedding... ;)
>
> Bikeshed away, I don't mind ... in this case :)
>
> I'm not super fond of this idea, though, I think because the names are
> all "useless" -- they don't have any meaning to any of the actual uses,
> they are just there for documentation purposes.
>
> One other random idea was something like:
>
> GCC_METHOD7 (gcc_decl, build_decl,
> const char *, /* Argument NAME. */
> enum gcc_c_symbol_kind, /* Argument SYM_KIND. */
LGTM.
Jakub