= @_; # Last statement should be just "1;" my @significant = grep { _is_code($_) } $doc->schildren(); my $match = $significant[-1]; return if !$match; return if ((ref $match) eq 'PPI::Statement' && $match =~ m{\A 1 \s* ; \z}xms ); # Must be a violation... return $self->violation( $DESC, $EXPL, $match ); } 148݄30༵
my $document = PPI::Document->new($file); my $package = $document->find_first( 'PPI::Statement::Package' ); my $package_name = $package->namespace; my $methods = $document->find( 'PPI::Statement::Sub' ); for my $method (@$methods) { my $document = PPI::Document->new($file); ...; } } } 148݄30༵