logo
Free, unlimited AI code reviews that run on commit
git-lrc git-lrc GitHub Install Now We'd appreciate a star git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt

Perl::Critic::Policy::Compatibility::PodMinimumVersion - check Perl version declared against POD features

Configuration

       "above_version" (version string, default none)
           Report  only  things  about Perl versions above this.  The string is anything the "version.pm" module
           understands.  For example if you always use Perl 5.6 or higher then set

               [Compatibility::PodMinimumVersion]
               above_version = 5.006

           The effect is that all POD features up to and including Perl 5.6 are allowed, only things above  that
           will be reported (and still only those exceeding any "use 5.xxx" in the file).

Description

       This policy is part of the "Perl::Critic::Pulp" add-on.  It checks that the POD features you use don't
       exceed your target Perl version as indicated by "use 5.008" etc.

           use 5.005;

           =pod

           C<< something >>    # bad, double angles needs 5.006

       POD doesn't affect how the code runs, so this policy is low severity, and under the "compatibility" theme
       (see "POLICY THEMES" in Perl::Critic).

       See "Pod::MinimumVersion" for the POD version checks applied.  The key idea is for example when targeting
       Perl 5.005 you avoid things like double-angles "C<< >>", since "pod2man" in 5.005 didn't support them.
       It may be possible to get newer versions of the POD translators from CPAN, but whether they run on an
       older Perl and whether you want to require that of users is another matter.

       Adding the sort of "use 5.006" etc to declare a target Perl can be a bit tedious.  The config option
       below lets you set a base version you use.  As always if you don't care at all about this sort of thing
       you can disable the policy from your .perlcriticrc in the usual way (see "CONFIGURATION" in
       Perl::Critic),

           [-Compatibility::PodMinimumVersion]

   "RequirePodLinksIncludeText"Policy
       The "Documentation::RequirePodLinksIncludeText" policy asks you to use the "L<target|display>" style
       always.  That feature is new in Perl 5.005 and will be reported by "PodMinimumVersion" unless you've got
       "use 5.005" or higher or set "above_version" below.

Home Page

Name

       Perl::Critic::Policy::Compatibility::PodMinimumVersion - check Perl version declared against POD features
       used

See Also

       Perl::Critic::Pulp, Pod::MinimumVersion, Perl::Critic

       Perl::Critic::Policy::Documentation::RequirePodLinksIncludeText,
       Perl::Critic::Policy::Compatibility::PerlMinimumVersionAndWhy,
       Perl::Critic::Policy::Modules::PerlMinimumVersion

See Also