pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Andrew Dunstan <andrew@dunslane.net>
To: John Naylor <john.naylor@enterprisedb.com>
To: Dagfinn Ilmari Mannsåker <ilmari@ilmari.org>
Cc: Alvaro Herrera <alvherre@alvh.no-ip.org>
Cc: pgsql-committers@lists.postgresql.org
Subject: Re: pgsql: Fix perltidy breaking perlcritic
Date: Tue, 13 Sep 2022 22:05:20 -0400
Message-ID: <cd7c9d7d-53bf-1a8f-669a-4c5ec6c601e6@dunslane.net> (raw)
In-Reply-To: <CAFBsxsGfpcxgnsJ2CoM+k7uWsMoNXXgqjRmOQBrxGeehw0oFgA@mail.gmail.com>
References: <E1oWDka-001ygS-TB@gemulon.postgresql.org>
	<CAD5tBcLLAvZO_x9X0=NePodXJCMowC8ieBAa6t_a0SeUu+rrfA@mail.gmail.com>
	<CAFBsxsG4yC4uUM6+fy=0RO0ZE6E=VRFJ6Eu6fBeairBUxtCunQ@mail.gmail.com>
	<CAD5tBc+zRhuWn_S4ayH2sWKe60FQu1guTTokDFS3YMOeSrsozA@mail.gmail.com>
	<8735cwncig.fsf@wibble.ilmari.org>
	<CAFBsxsGfpcxgnsJ2CoM+k7uWsMoNXXgqjRmOQBrxGeehw0oFgA@mail.gmail.com>


On 2022-09-13 Tu 05:25, John Naylor wrote:
> On Mon, Sep 12, 2022 at 4:54 PM Dagfinn Ilmari Mannsåker
> <ilmari@ilmari.org> wrote:
>
>>> eval "\$hash_ref = $_";  ## no critic (ProhibitStringyEval)
>> I didn't see this until it got committed, since I'm not subscribed to
>> -committers, but I think it would be even better to rely on the fact
>> that eval returns the value of the last expression in the string, which
>> also gets rid of the ugly quoting and escaping, per the attached.
> Hmm, interesting.



I agree it's a slight stylistic improvement. I was trying to keep as
close as possible to the original.


cheers


andrew

--
Andrew Dunstan
EDB: https://www.enterprisedb.com






view thread (8+ messages)

Message-ID: <cd7c9d7d-53bf-1a8f-669a-4c5ec6c601e6@dunslane.net>
Permalink:  ../cd7c9d7d-53bf-1a8f-669a-4c5ec6c601e6@dunslane.net/
Also on:    postgresql.org/message-id/cd7c9d7d-53bf-1a8f-669a-4c5ec6c601e6@dunslane.net

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-committers@postgresql.org
  Cc: andrew@dunslane.net, john.naylor@enterprisedb.com, ilmari@ilmari.org, alvherre@alvh.no-ip.org
  Subject: Re: pgsql: Fix perltidy breaking perlcritic
  In-Reply-To: <cd7c9d7d-53bf-1a8f-669a-4c5ec6c601e6@dunslane.net>
  References: <E1oWDka-001ygS-TB@gemulon.postgresql.org> <CAD5tBcLLAvZO_x9X0=NePodXJCMowC8ieBAa6t_a0SeUu+rrfA@mail.gmail.com> <CAFBsxsG4yC4uUM6+fy=0RO0ZE6E=VRFJ6Eu6fBeairBUxtCunQ@mail.gmail.com> <CAD5tBc+zRhuWn_S4ayH2sWKe60FQu1guTTokDFS3YMOeSrsozA@mail.gmail.com> <8735cwncig.fsf@wibble.ilmari.org> <CAFBsxsGfpcxgnsJ2CoM+k7uWsMoNXXgqjRmOQBrxGeehw0oFgA@mail.gmail.com> <cd7c9d7d-53bf-1a8f-669a-4c5ec6c601e6@dunslane.net>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox