ePages 6.13.3 - DE_EPAGES/Core/Scripts/Perl/Critic/Policy/DE_EPAGES/Style/RequireCommentForExportedFunctions.pm

Package Perl::Critic::Policy::DE_EPAGES::Style::RequireCommentForExportedFunctions

This module checks if exported functions have a comment This module acts as a custom policy for Perl::Critic. Perl::Critic uses Module::Pluggable to automatically discover all modules in the Perl::Critic::Policy namespace, which is the reason we put this module beyond Perl::Critic::Policy. This policy checks if public packages (§state is not set to private) have package comments. At least the following values have to be set - \# - \ This policy also iterates over all subs (functions) in the currently tested module. For subs that are part of the EXPORTS-List of the module, a documentation is mandatory. In other cases, if documentation is found, it is also checked for correctness. Whenever common content is missing, a violation is returned. Common content of documentation are: - \§function - \§state - \ - \§syntax - Each input variable should be described usng an \§input entry. - If the function returns anything else than undef, there has to be a \§return comment Exceptions: Currently there's a number of "allowed" violations that are not reported: - "return 1;" in some functions created by our code generator is not documented and should be replaced by "return;" - §parameters none