| 1 | package Perl::Critic::Policy::Freenode::IndirectObjectNotation; | ||
| 2 | |||
| 3 | 1 | ▶ | use strict; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 4 | 1 | ▶ | use warnings; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 5 | |||
| 6 | 1 | ▶ | use parent 'Perl::Critic::Policy::Community::IndirectObjectNotation'; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 7 | |||
| 8 | 1 | our $VERSION = 'v1.0.4'; | |
| 9 | |||
| 10 | 0 | ▶ | sub default_themes { 'freenode' } |
|
Subroutine
default_themes: not called CC=1 SCAR=6.9
Pod
documented
| |||
| 11 | |||
| 12 | 1 | 1; | |
| 13 | |||
| 14 | =head1 NAME | ||
| 15 | |||
| 16 | Perl::Critic::Policy::Freenode::IndirectObjectNotation - Don't call methods | ||
| 17 | indirectly (DEPRECATED) | ||
| 18 | |||
| 19 | =head1 DESCRIPTION | ||
| 20 | |||
| 21 | Legacy C<freenode> theme policy alias. | ||
| 22 | |||
| 23 | =head1 POLICY MOVED | ||
| 24 | |||
| 25 | This policy has been moved to L<Perl::Critic::Community>. | ||
| 26 | |||
| 27 | =head1 AFFILIATION | ||
| 28 | |||
| 29 | This policy is part of L<Perl::Critic::Freenode>. | ||
| 30 | |||
| 31 | =head1 CONFIGURATION | ||
| 32 | |||
| 33 | This policy can be configured, in the same way as its parent policy | ||
| 34 | L<Perl::Critic::Policy::Objects::ProhibitIndirectSyntax>, to attempt to forbid | ||
| 35 | additional method names from being called indirectly. Be aware this may lead to | ||
| 36 | false positives as it is difficult to detect indirect object notation by static | ||
| 37 | analysis. The C<new> subroutine is always forbidden in addition to these. | ||
| 38 | |||
| 39 | [Freenode::IndirectObjectNotation] | ||
| 40 | forbid = create destroy | ||
| 41 | |||
| 42 | =head1 AUTHOR | ||
| 43 | |||
| 44 | Dan Book, C<dbook@cpan.org> | ||
| 45 | |||
| 46 | =head1 COPYRIGHT AND LICENSE | ||
| 47 | |||
| 48 | Copyright 2015, Dan Book. | ||
| 49 | |||
| 50 | This library is free software; you may redistribute it and/or modify it under | ||
| 51 | the terms of the Artistic License version 2.0. | ||
| 52 | |||
| 53 | =head1 SEE ALSO | ||
| 54 | |||
| 55 | L<Perl::Critic>, L<Perl::Critic::Community> | ||