in reply to Re^2: perlcritic and heredocs
in thread perlcritic and heredocs

I downloaded the code, removed the ## comments, included the standard boilerplate for scripts (shebang, strictures, warnings) and run freshly installed perlcritic on it:
$ perlcritic --force -1 1.pl Code is not tidy at line 1, column 1. See page 33 of PBP. (Severity: + 1) No package-scoped "$VERSION" variable found at line 1, column 1. See +page 404 of PBP. (Severity: 2) Regular expression without "/s" flag at line 6, column 38. See pages +240,241 of PBP. (Severity: 2)

map{substr$_->[0],$_->[1]||0,1}[\*||{},3],[[]],[ref qr-1,-,-1],[{}],[sub{}^*ARGV,3]

Replies are listed 'Best First'.
Re^4: perlcritic and heredocs
by Fletch (Bishop) on Apr 15, 2020 at 15:09 UTC

    Very tangentially related but: perl (and perlcritic) will honour cpp-style #line filename linenumber directives so you can embed those in disjoint snippets to get line numbers to line up (as it were) with the original full source.

    Update: additionally I get the same output (perlcritic 1.138, perl 5.30.2) albeit with the regex error reported at line 4483 since I diddled in #line 4483 before the first line of code after similar shebang/strict/warnings.

    The cake is a lie.
    The cake is a lie.
    The cake is a lie.