Re: typedef indentation in pg_shmem.h - Mailing list pgsql-hackers

From Tom Lane
Subject Re: typedef indentation in pg_shmem.h
Date
Msg-id 3935968.1768230117@sss.pgh.pa.us
Whole thread Raw
In response to typedef indentation in pg_shmem.h  (Ashutosh Bapat <ashutosh.bapat.oss@gmail.com>)
Responses Re: typedef indentation in pg_shmem.h
List pgsql-hackers
Ashutosh Bapat <ashutosh.bapat.oss@gmail.com> writes:
> The typedefs PGShmemType and HugePagesType are not indented properly.
> That's because those entries are missing from typedefs list. Is that
> intentional?

The reason this happens is that the automatic process for collecting
typedefs in the buildfarm only picks up typedef names that are used
to declare objects (variables, struct fields, function parameters or
results).

AFAICS neither of these typedef names are referenced at all, anywhere.

> Here's tiny patch fixing the indentation and typedefs
> list.

I don't think this is helpful, because that change will just get
undone the next time we absorb the buildfarm's list.  (And to be
clear, I consider the buildfarm's list to be the canonical one.)

I think the right way is to remove the unused typedefs, that is
along the lines of

-typedef enum
+enum HugePagesType
 {
...
-}            HugePagesType;
+};

We can put them back when/if there's a reason to use them.

            regards, tom lane



pgsql-hackers by date:

Previous
From: Robert Haas
Date:
Subject: Re: pg_plan_advice
Next
From: Tom Lane
Date:
Subject: Re: Maybe BF "timedout" failures are the client script's fault?