This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH] Fix names of various macro parameters in tree.h
- From: Richard Biener <richard dot guenther at gmail dot com>
- To: David Malcolm <dmalcolm at redhat dot com>
- Cc: GCC Patches <gcc-patches at gcc dot gnu dot org>
- Date: Fri, 25 Oct 2013 10:39:40 +0200
- Subject: Re: [PATCH] Fix names of various macro parameters in tree.h
- Authentication-results: sourceware.org; auth=none
- References: <1382663848 dot 2675 dot 112 dot camel at surprise>
On Fri, Oct 25, 2013 at 3:17 AM, David Malcolm <dmalcolm@redhat.com> wrote:
> I noticed that some of the macros in tree.h that act on trees have
> parameters named "CODE", rather "NODE", which is confusing when in the
> presence of other macros that act on enum tree_code values.
>
> The attached patch renames such params for macros that I believe act on
> trees (mostly because they go ahead and lookup the TREE_CODE() of the
> param).
>
> Successfully bootstrapped®tested on x86_64-unknown-linux.
>
> OK for trunk?
Ok.
Thanks,
Richard.
> (fwiw the macros appear to have been this way since they were introduced
> in 87675 in 2004-09-17)
>
> gcc/
> * tree.h (EXCEPTIONAL_CLASS_P): Rename parameter from "CODE"
> to "NODE", since this works on a "tree", not an
> "enum tree_code".
> (CONSTANT_CLASS_P): Likewise.
> (TYPE_P): Likewise.
> (DECL_P): Likewise.
> (INDIRECT_REF_P): Likewise.
> (REFERENCE_CLASS_P): Likewise.
> (COMPARISON_CLASS_P): Likewise.
> (UNARY_CLASS_P): Likewise.
> (BINARY_CLASS_P): Likewise.
> (STATEMENT_CLASS_P): Likewise.
> (VL_EXP_CLASS_P): Likewise.
> (EXPRESSION_CLASS_P): Likewise.
> (IS_TYPE_OR_DECL_P): Likewise.
>