Re: [HACKERS] removal of braces - Mailing list pgsql-hackers

From Bruce Momjian
Subject Re: [HACKERS] removal of braces
Date
Msg-id 199806152055.QAA13926@candle.pha.pa.us
Whole thread Raw
In response to removal of braces  (Bruce Momjian <maillist@candle.pha.pa.us>)
Responses Re: [HACKERS] removal of braces
List pgsql-hackers
>
> I have written a script to remove braces around single statements, if
> the statement is only one line in length.
>
> The macro fixup context diff was 1,200 lines, and this diff is 12k
> lines.
>
> Hope no one is sitting on patches.

They had things like:

    if (test != 0)
        macro;

while the macro was:

#define macro() \
    stmt1; \
    stmt2; \
    stmt3;

Of course, only the stmt1 is conditional.  The rest are always executed.
I am sure there were some bugs fixed by this cleanup.

--
Bruce Momjian                          |  830 Blythe Avenue
maillist@candle.pha.pa.us              |  Drexel Hill, Pennsylvania 19026
  +  If your life is a hard drive,     |  (610) 353-9879(w)
  +  Christ can be your backup.        |  (610) 853-3000(h)

pgsql-hackers by date:

Previous
From: Bruce Momjian
Date:
Subject: Re: [HACKERS] template portname problems
Next
From: dg@illustra.com (David Gould)
Date:
Subject: Re: [HACKERS] removal of braces