This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: c-gimplify.c:gimplify_decl_stmt
- From: Eric Christopher <echristo at redhat dot com>
- To: Richard Kenner <kenner at vlsi1 dot ultra dot nyu dot edu>
- Cc: gcc at gcc dot gnu dot org
- Date: Sun, 06 Jun 2004 12:13:29 -0700
- Subject: Re: c-gimplify.c:gimplify_decl_stmt
- References: <10406061907.AA01318@vlsi1.ultra.nyu.edu>
On Sun, 2004-06-06 at 12:07, Richard Kenner wrote:
> > The comments in front of the funciton reference variables inside the
> > function, which is wrong.
>
> I don't know that this is "wrong" as long as it's useful. Describing the
> algorithm or high level stuff that's needed to understand the function.
>
> No, it's confusing.
>
> Comments *before* the function are supposed to explain the *specification*
> of the function, which means what a *caller* of the function needs to know.
>
I disagree. There's nothing at all wrong with describing the function
itself and what it does and how it works. I've just taken a look at the
comment and it does appear to be split along specification and
description boundaries. Seems very useful to me. I've often wanted this
for other functions. Also, it seems a good way to keep functions small
and to the point - otherwise we get fold (). :)
-eric
--
Eric Christopher <echristo@redhat.com>