Re: pgsql: Fix perltidy breaking perlcritic

From: John Naylor <john(dot)naylor(at)enterprisedb(dot)com>
To: Andrew Dunstan <andrew(at)dunslane(dot)net>
Cc: Alvaro Herrera <alvherre(at)alvh(dot)no-ip(dot)org>, pgsql-committers(at)lists(dot)postgresql(dot)org
Subject: Re: pgsql: Fix perltidy breaking perlcritic
Date: 2022-09-10 02:44:44
Message-ID: CAFBsxsG4yC4uUM6+fy=0RO0ZE6E=VRFJ6Eu6fBeairBUxtCunQ@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-committers pgsql-hackers

On Fri, Sep 9, 2022 at 3:32 AM Andrew Dunstan <andrew(at)dunslane(dot)net> wrote:

> A better way do do this IMNSHO is to put the eval in a block on its own along with the no critic marker on its own line, like this:
>
> {
> ## no critic (ProhibitStringyEval)
> eval ...
> }
>
> perlcritic respects block boundaries for its directives.

I tried that in the attached -- it looks a bit nicer but requires more
explanation. I don't have strong feelings either way.

--
John Naylor
EDB: http://www.enterprisedb.com

Attachment Content-Type Size
perlcritic-block-scope.patch text/x-patch 917 bytes

In response to

Responses

Browse pgsql-committers by date

  From Date Subject
Next Message Tom Lane 2022-09-10 04:14:26 Re: pgsql: aix: No need to use mkldexport when we want to export all symbol
Previous Message Andres Freund 2022-09-10 02:12:49 pgsql: aix: No need to use mkldexport when we want to export all symbol

Browse pgsql-hackers by date

  From Date Subject
Next Message Justin Pryzby 2022-09-10 02:57:56 Re: pg15b4: FailedAssertion("TransactionIdIsValid(xmax)
Previous Message Lev Kokotov 2022-09-10 02:38:14 Support for Rust