Re: pgsql: ecpg: Output dir, source dir, stamp file argument for preproc/*.

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Andres Freund <andres(at)anarazel(dot)de>
Cc: pgsql-committers(at)lists(dot)postgresql(dot)org, Andrew Dunstan <andrew(at)dunslane(dot)net>
Subject: Re: pgsql: ecpg: Output dir, source dir, stamp file argument for preproc/*.
Date: 2022-07-18 21:14:32
Message-ID: 819625.1658178872@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-committers

Andres Freund <andres(at)anarazel(dot)de> writes:
> ecpg: Output dir, source dir, stamp file argument for preproc/*.pl

crake says that perlcritic doesn't like this:

Jul 18 16:48:25 ./src/interfaces/ecpg/preproc/parse.pl: Bareword file handle opened at line 30, column 1. See pages 202,204 of PBP. ([InputOutput::ProhibitBarewordFileHandles] Severity: 5)
Jul 18 16:48:25 ./src/interfaces/ecpg/preproc/parse.pl: Bareword file handle opened at line 31, column 1. See pages 202,204 of PBP. ([InputOutput::ProhibitBarewordFileHandles] Severity: 5)

That's bitching about

open(our $parserfh, '<', $parser) or die "could not open parser file $parser";
open(our $outfh, '>', $outfile) or die "could not open output file $outfile";

which doesn't look like a bareword to my non-perl-monk eye,
but what do I know? Maybe you should be using "my" instead
of "our", because I don't see anything else about it that looks
different from other places in our code.

regards, tom lane

In response to

Browse pgsql-committers by date

  From Date Subject
Next Message Tom Lane 2022-07-18 21:27:21 Re: pgsql: ecpg: Output dir, source dir, stamp file argument for preproc/*.
Previous Message Andres Freund 2022-07-18 21:14:08 Re: pgsql: ecpg: Output dir, source dir, stamp file argument for preproc/*.