Thread: Typo in comment of auto_explain.c
Hi everyone, I found typo in comment auto_explain.c line 282 (/* Enable per-node instrumentation iff log_analyze is required. */). Not 'iff' but 'if'. -- Best regards, Ilia Evdokimov, Tantor Labs LLC.
> On 27 Nov 2024, at 13:46, Ilia Evdokimov <ilya.evdokimov@tantorlabs.com> wrote: > I found typo in comment auto_explain.c line 282 (/* Enable per-node instrumentation iff log_analyze is required. */). > > Not 'iff' but 'if'. iff is a shorthand for "if and only if", which is used throughout the code. Given the number of reports of typos we've had over the years it's discouraged from use in new code. -- Daniel Gustafsson
On 27/11/2024 14:46, Ilia Evdokimov wrote: > Hi everyone, > > I found typo in comment auto_explain.c line 282 (/* Enable per-node > instrumentation iff log_analyze is required. */). > > Not 'iff' but 'if'. It's short for "if and only if". See https://en.wikipedia.org/wiki/If_and_only_if. There was some previous discussion on pgsql-hackers on whether that usage common enough, although I don't find the thread right now. You're not the first one to think it's a typo :-). -- Heikki Linnakangas Neon (https://neon.tech)
On 27.11.2024 15:54, Heikki Linnakangas wrote: > On 27/11/2024 14:46, Ilia Evdokimov wrote: >> Hi everyone, >> >> I found typo in comment auto_explain.c line 282 (/* Enable per-node >> instrumentation iff log_analyze is required. */). >> >> Not 'iff' but 'if'. > > It's short for "if and only if". See > https://en.wikipedia.org/wiki/If_and_only_if. > > There was some previous discussion on pgsql-hackers on whether that > usage common enough, although I don't find the thread right now. > You're not the first one to think it's a typo :-). > Ah, now everything is clear. I need to look at history of pgsql-hackers more often. Then there are no questions. Thanks.