Re: pgsql: Fix precedence problem in new Perl code.

2018-05-05 Thread Andrew Dunstan
On Fri, May 4, 2018 at 5:28 PM, Mike Blackwell wrote: > I didn't see a .perlcriticrc file in the project, so ran with our local > settings. > > With those, perlcritic is pretty unhappy, even at -4, though I don't see > anything that pops out as potentially bug-inducing. The ones I'd probably > lo

Re: pgsql: Fix precedence problem in new Perl code.

2018-05-04 Thread Mike Blackwell
I didn't see a .perlcriticrc file in the project, so ran with our local settings. With those, perlcritic is pretty unhappy, even at -4, though I don't see anything that pops out as potentially bug-inducing. The ones I'd probably look fixing at for starters would be the two argument form of open,

Re: pgsql: Fix precedence problem in new Perl code.

2018-05-04 Thread Tom Lane
Mike Blackwell writes: > In my experience, that would more commonly be written with the lower > precedence "or" operator (with or without the param list parens): > unlink $temp_name or die "unlink: $temp_name: $!"; Yeah, I thought about that, but the pre-existing rename call had || and I didn't

Re: pgsql: Fix precedence problem in new Perl code.

2018-05-04 Thread Mike Blackwell
In my experience, that would more commonly be written with the lower precedence "or" operator (with or without the param list parens): unlink $temp_name or die "unlink: $temp_name: $!"; __ *Mike Blackwell | Technical

pgsql: Fix precedence problem in new Perl code.

2018-05-04 Thread Tom Lane
Fix precedence problem in new Perl code. I think this bit of commit 1f1cd9b5d didn't do quite what I meant :-( Branch -- master Details --- https://git.postgresql.org/pg/commitdiff/59cb323053f4ed582d4e71acaeb5770603f074db Modified Files -- src/backend/catalog/Catalog.pm | 2