On 05.12.22 18:04, Robert Haas wrote:
On Mon, Dec 5, 2022 at 11:51 AM Tom Lane wrote:
Robert Haas writes:
I was only talking about the actual argument to getopt(), not the
order of the code stanzas. I'm not sure what we ought to do about the
latter.
100% agreed that the getopt argument shou
On Mon, Dec 5, 2022 at 11:51 AM Tom Lane wrote:
> Robert Haas writes:
> > I was only talking about the actual argument to getopt(), not the
> > order of the code stanzas. I'm not sure what we ought to do about the
> > latter.
>
> 100% agreed that the getopt argument should just be alphabetical.
>
Robert Haas writes:
> I was only talking about the actual argument to getopt(), not the
> order of the code stanzas. I'm not sure what we ought to do about the
> latter.
100% agreed that the getopt argument should just be alphabetical.
But the bulk of Peter's patch is rearranging switch cases to
On Mon, Dec 5, 2022 at 11:14 AM Tom Lane wrote:
> Robert Haas writes:
> > +1 for Peter's proposal to just alphabetize. That's easy to maintain,
> > at least in theory.
>
> Agreed for single-letter options. Long options complicate matters:
> are we going to order their code stanzas by the actual
Robert Haas writes:
> +1 for Peter's proposal to just alphabetize. That's easy to maintain,
> at least in theory.
Agreed for single-letter options. Long options complicate matters:
are we going to order their code stanzas by the actual long name, or
by the character/number returned by getopt? O
On Mon, Dec 5, 2022 at 3:42 AM Fabien COELHO wrote:
> > I had noticed that most getopt() or getopt_long() calls had their letter
> > lists in pretty crazy orders. There might have been occasional attempts
> > at grouping, but those then haven't been maintained as new options were
> > added. To re
Hello Peter,
I had noticed that most getopt() or getopt_long() calls had their letter
lists in pretty crazy orders. There might have been occasional attempts
at grouping, but those then haven't been maintained as new options were
added. To restore some sanity to this, I went through and ord
them
alphabetically.From 022b6f7665e7f38fd773f7d44c892344b714f795 Mon Sep 17 00:00:00 2001
From: Peter Eisentraut
Date: Mon, 5 Dec 2022 09:15:53 +0100
Subject: [PATCH] Order getopt arguments
Order the letters in the arguments of getopt() and getopt_long(), as
well as in the subsequent switch state