App-ZodiacUtils
view release on metacpan or search on metacpan
script/_zodiac-of view on Meta::CPAN
Complete/Getopt/Long.pm,72670,36047,5;2353
Complete/Path.pm,108742,13757,6;3338
Complete/Sah.pm,122523,16328,7;3755
Complete/Tcsh.pm,138876,6850,8;4197
Complete/Util.pm,145751,40883,9;4453
Data/Clean.pm,186656,17013,10;5871
Data/Clean/ForJSON.pm,203699,8992,11;6443
Data/Clean/FromJSON.pm,212722,3100,12;6736
Data/Dmp.pm,215842,13835,13;6860
Data/ModeMerge.pm,229703,26971,14;7309
Data/ModeMerge/Config.pm,256707,14454,15;8094
Data/ModeMerge/Mode/ADD.pm,271196,2657,16;8618
Data/ModeMerge/Mode/Base.pm,273889,22041,17;8738
Data/ModeMerge/Mode/CONCAT.pm,295968,1741,18;9411
Data/ModeMerge/Mode/DELETE.pm,297747,2738,19;9490
Data/ModeMerge/Mode/KEEP.pm,300521,2463,20;9620
Data/ModeMerge/Mode/NORMAL.pm,303022,2800,21;9739
Data/ModeMerge/Mode/SUBTRACT.pm,305862,3373,22;9883
Data/Sah/Normalize.pm,309265,9038,23;10026
Data/Sah/Resolve.pm,318331,7505,24;10300
Data/Sah/Util/Type.pm,325866,9456,25;10539
Function/Fallback/CoreOrPP.pm,335360,5030,26;10839
Getopt/Long/Negate/EN.pm,340423,5332,27;11034
Getopt/Long/Util.pm,345783,17134,28;11183
Lingua/EN/PluralToSingular.pm,362955,14259,29;11813
Log/ger.pm,377233,11278,30;12560
Log/ger/Filter.pm,388537,1149,31;12905
Log/ger/Filter/Code.pm,389717,1395,32;12971
Log/ger/Format.pm,391138,1293,33;13053
Log/ger/Format/Default.pm,392465,3299,34;13126
Log/ger/Format/None.pm,395795,1269,35;13244
Log/ger/Heavy.pm,397089,18144,36;13311
Log/ger/Layout.pm,415259,1229,37;13712
Log/ger/Output.pm,416514,1358,38;13780
Log/ger/Output/Array.pm,417904,1585,39;13859
Log/ger/Output/Null.pm,419520,1273,40;13945
Log/ger/Output/String.pm,420826,2305,41;14013
Log/ger/Plugin.pm,423157,2038,42;14118
Log/ger/Plugin/MultilevelLog.pm,425235,5006,43;14233
Log/ger/Util.pm,430265,10231,44;14412
Mo.pm,440510,591,45;14740
Mo/Golf.pm,441120,8174,46;14744
Mo/Inline.pm,449315,3471,47;14980
Mo/Moose.pm,452806,533,48;15121
Mo/Mouse.pm,453359,563,49;15126
Mo/build.pm,453942,248,50;15131
Mo/builder.pm,454212,338,51;15135
Mo/chain.pm,454570,216,52;15139
Mo/coerce.pm,454807,330,53;15143
Mo/default.pm,455159,435,54;15147
Mo/exporter.pm,455617,176,55;15151
Mo/import.pm,455814,185,56;15155
Mo/importer.pm,456022,207,57;15159
Mo/is.pm,456246,228,58;15163
Mo/nonlazy.pm,456496,129,59;15167
Mo/option.pm,456646,259,60;15171
Mo/required.pm,456928,340,61;15175
Mo/xs.pm,457285,256,62;15179
Module/Installed/Tiny.pm,457574,7196,63;15183
Perinci/Sub/Complete.pm,464802,55886,64;15418
Perinci/Sub/GetArgs/Argv.pm,520724,55430,65;17015
Perinci/Sub/GetArgs/Array.pm,576191,7479,66;18508
Perinci/Sub/Normalize.pm,583703,7303,67;18768
Perinci/Sub/Util.pm,591034,21083,68;19003
Perinci/Sub/Util/Args.pm,612150,6274,69;19764
Perinci/Sub/Util/ResObj.pm,618459,1545,70;20018
Perinci/Sub/Util/Sort.pm,620037,1957,71;20079
Regexp/Stringify.pm,622022,5418,72;20170
Sah/Schema/rinci/function_meta.pm,627482,7126,73;20367
Sah/Schema/rinci/meta.pm,634641,3699,74;20633
Sah/Schema/rinci/result_meta.pm,638380,3586,75;20797
Sah/SchemaR/rinci/function_meta.pm,642009,6238,76;20952
Sah/SchemaR/rinci/meta.pm,648281,3012,77;21010
Sah/SchemaR/rinci/result_meta.pm,651334,2346,78;21068
Sah/Schemas/Rinci.pm,653709,1286,79;21126
String/LineNumber.pm,655024,2512,80;21182
String/PerlQuote.pm,657564,3383,81;21300
String/Wildcard/Bash.pm,660979,9637,82;21425
YAML/Old.pm,670636,3321,83;21755
YAML/Old/Dumper.pm,673984,17730,84;21872
YAML/Old/Dumper/Base.pm,691746,3735,85;22449
YAML/Old/Error.pm,695507,5985,86;22560
YAML/Old/Loader.pm,701519,25286,87;22751
YAML/Old/Loader/Base.pm,726837,1235,88;23522
YAML/Old/Marshall.pm,728101,934,89;23559
YAML/Old/Mo.pm,729058,3416,90;23606
YAML/Old/Node.pm,732499,4692,91;23686
YAML/Old/Tag.pm,737215,240,92;23904
YAML/Old/Types.pm,737481,6708,93;23923
### Clone/PP.pm ###
#package Clone::PP;
#
#use 5.006;
#use strict;
#use warnings;
#use vars qw($VERSION @EXPORT_OK);
#use Exporter;
#
#$VERSION = 1.07;
#
#@EXPORT_OK = qw( clone );
#sub import { goto &Exporter::import } # lazy Exporter
#
## These methods can be temporarily overridden to work with a given class.
#use vars qw( $CloneSelfMethod $CloneInitMethod );
#$CloneSelfMethod ||= 'clone_self';
#$CloneInitMethod ||= 'clone_init';
#
## Used to detect looped networks and avoid infinite recursion.
#use vars qw( %CloneCache );
#
## Generic cloning function
#sub clone {
# my $source = shift;
#
# return undef if not defined($source);
#
# # Optional depth limit: after a given number of levels, do shallow copy.
# my $depth = shift;
# return $source if ( defined $depth and $depth -- < 1 );
script/_zodiac-of view on Meta::CPAN
#
#Bool. If set to true, will generated more log statements for debugging (at the
#trace level).
#
#=head2 COMPLETE_GETOPT_LONG_DEFAULT_ENV
#
#Bool. Default true. Can be set to false to disable completing from environment
#variable in default completion.
#
#=head2 COMPLETE_GETOPT_LONG_DEFAULT_FILE
#
#Bool. Default true. Can be set to false to disable completing from filesystem
#(file and directory names) in default completion.
#
#=head1 HOMEPAGE
#
#Please visit the project's homepage at L<https://metacpan.org/release/Complete-Getopt-Long>.
#
#=head1 SOURCE
#
#Source repository is at L<https://github.com/perlancar/perl-Complete-Getopt-Long>.
#
#=head1 BUGS
#
#Please report any bugs or feature requests on the bugtracker website L<https://rt.cpan.org/Public/Dist/Display.html?Name=Complete-Getopt-Long>
#
#When submitting a bug or request, please include a test-file or a
#patch to an existing test-file that illustrates the bug or desired
#feature.
#
#=head1 SEE ALSO
#
#L<Getopt::Long::Complete>
#
#L<Complete>
#
#L<Complete::Bash>
#
#Other modules related to bash shell tab completion: L<Bash::Completion>,
#L<Getopt::Complete>.
#
#L<Perinci::CmdLine> - an alternative way to easily create command-line
#applications with completion feature.
#
#=head1 AUTHOR
#
#perlancar <perlancar@cpan.org>
#
#=head1 COPYRIGHT AND LICENSE
#
#This software is copyright (c) 2020, 2019, 2017, 2016, 2015, 2014 by perlancar@cpan.org.
#
#This is free software; you can redistribute it and/or modify it under
#the same terms as the Perl 5 programming language system itself.
#
#=cut
### Complete/Path.pm ###
#package Complete::Path;
#
#our $DATE = '2017-07-03'; # DATE
#our $VERSION = '0.24'; # VERSION
#
#use 5.010001;
#use strict;
#use warnings;
#
#use Complete::Common qw(:all);
#
#our $COMPLETE_PATH_TRACE = $ENV{COMPLETE_PATH_TRACE} // 0;
#
#require Exporter;
#our @ISA = qw(Exporter);
#our @EXPORT_OK = qw(
# complete_path
# );
#
#sub _dig_leaf {
# my ($p, $list_func, $is_dir_func, $filter_func, $path_sep) = @_;
# my $num_dirs;
# my $listres = $list_func->($p, '', 0);
# return $p unless ref($listres) eq 'ARRAY' && @$listres;
# my @candidates;
# L1:
# for my $e (@$listres) {
# my $p2 = $p =~ m!\Q$path_sep\E\z! ? "$p$e" : "$p$path_sep$e";
# {
# local $_ = $p2; # convenience for filter func
# next L1 if $filter_func && !$filter_func->($p2);
# }
# push @candidates, $p2;
# }
# return $p unless @candidates == 1;
# my $p2 = $candidates[0];
# my $is_dir;
# if ($p2 =~ m!\Q$path_sep\E\z!) {
# $is_dir++;
# } else {
# $is_dir = $is_dir_func && $is_dir_func->($p2);
# }
# return _dig_leaf($p2, $list_func, $is_dir_func, $filter_func, $path_sep)
# if $is_dir;
# $p2;
#}
#
#our %SPEC;
#
#$SPEC{complete_path} = {
# v => 1.1,
# summary => 'Complete path',
# description => <<'_',
#
#Complete path, for anything path-like. Meant to be used as backend for other
#functions like `Complete::File::complete_file` or
#`Complete::Module::complete_module`. Provides features like case-insensitive
#matching, expanding intermediate paths, and case mapping.
#
#Algorithm is to split path into path elements, then list items (using the
#supplied `list_func`) and perform filtering (using the supplied `filter_func`)
#at every level.
#
#_
script/_zodiac-of view on Meta::CPAN
# "$dir$e" : "$dir$path_sep$e";
# #say "D:p=$p";
# {
# local $_ = $p; # convenience for filter func
# next L1 if $filter_func && !$filter_func->($p);
# }
#
# my $is_dir;
# if ($e =~ $re_ends_with_path_sep) {
# $is_dir = 1;
# } else {
# local $_ = $p; # convenience for is_dir_func
# $is_dir = $is_dir_func->($p);
# }
#
# if ($is_dir && $dig_leaf) {
# {
# my $p2 = _dig_leaf($p, $list_func, $is_dir_func, $filter_func, $path_sep);
# last if $p2 eq $p;
# $p = $p2;
# #say "D:p=$p (dig_leaf)";
#
# # check again
# if ($p =~ $re_ends_with_path_sep) {
# $is_dir = 1;
# } else {
# local $_ = $p; # convenience for is_dir_func
# $is_dir = $is_dir_func->($p);
# }
# }
# }
#
# # process into final result
# my $p0 = $p;
# substr($p, 0, $cut_chars) = '' if $cut_chars;
# $p = "$result_prefix$p" if length($result_prefix);
# unless ($p =~ /\Q$path_sep\E\z/) {
# $p .= $path_sep if $is_dir;
# }
# push @res, $p;
# }
# }
#
# \@res;
#}
#1;
## ABSTRACT: Complete path
#
#__END__
#
#=pod
#
#=encoding UTF-8
#
#=head1 NAME
#
#Complete::Path - Complete path
#
#=head1 VERSION
#
#This document describes version 0.24 of Complete::Path (from Perl distribution Complete-Path), released on 2017-07-03.
#
#=head1 DESCRIPTION
#
#=head1 FUNCTIONS
#
#
#=head2 complete_path
#
#Usage:
#
# complete_path(%args) -> array
#
#Complete path.
#
#Complete path, for anything path-like. Meant to be used as backend for other
#functions like C<Complete::File::complete_file> or
#C<Complete::Module::complete_module>. Provides features like case-insensitive
#matching, expanding intermediate paths, and case mapping.
#
#Algorithm is to split path into path elements, then list items (using the
#supplied C<list_func>) and perform filtering (using the supplied C<filter_func>)
#at every level.
#
#This function is not exported by default, but exportable.
#
#Arguments ('*' denotes required arguments):
#
#=over 4
#
#=item * B<filter_func> => I<code>
#
#Provide extra filtering. Code will be given path and should return 1 if the item
#should be included in the final result or 0 if the item should be excluded.
#
#=item * B<is_dir_func> => I<code>
#
#Function to check whether a path is a "dir".
#
#Optional. You can provide this function to determine if an item is a "directory"
#(so its name can be suffixed with path separator). You do not need to do this if
#you already suffix names of "directories" with path separator in C<list_func>.
#
#One reason you might want to provide this and not mark "directories" in
#C<list_func> is when you want to do extra filtering with C<filter_func>. Sometimes
#you do not want to suffix the names first (example: see C<complete_file> in
#C<Complete::File>).
#
#=item * B<list_func>* => I<code>
#
#Function to list the content of intermediate "dirs".
#
#Code will be called with arguments: ($path, $cur_path_elem, $is_intermediate).
#Code should return an arrayref containing list of elements. "Directories" can be
#marked by ending the name with the path separator (see C<path_sep>). Or, you can
#also provide an C<is_dir_func> function that will be consulted after filtering.
#If an item is a "directory" then its name will be suffixed with a path
#separator by C<complete_path()>.
#
#=item * B<path_sep> => I<str> (default: "/")
#
script/_zodiac-of view on Meta::CPAN
#customize options.
#
#=head2 CLASS->new() => $obj
#
#=head2 $obj->clean_in_place($data) => $cleaned
#
#Clean $data. Modify data in-place.
#
#=head2 $obj->clone_and_clean($data) => $cleaned
#
#Clean $data. Clone $data first.
#
#=head1 FAQ
#
#=head2 Why am I getting 'Modification of a read-only value attempted at lib/Data/Clean.pm line xxx'?
#
#[2013-10-15 ] This is also from Data::Clone::clone() when it encounters
#JSON::{PP,XS}::Boolean objects. You can use clean_in_place() instead of
#clone_and_clean(), or clone your data using other cloner like L<Sereal>.
#
#=head1 ENVIRONMENT
#
#LOG_CLEANSER_CODE
#
#=head1 HOMEPAGE
#
#Please visit the project's homepage at L<https://metacpan.org/release/Data-Clean-ForJSON>.
#
#=head1 SOURCE
#
#Source repository is at L<https://github.com/perlancar/perl-Data-Clean-ForJSON>.
#
#=head1 BUGS
#
#Please report any bugs or feature requests on the bugtracker website L<https://rt.cpan.org/Public/Dist/Display.html?Name=Data-Clean-ForJSON>
#
#When submitting a bug or request, please include a test-file or a
#patch to an existing test-file that illustrates the bug or desired
#feature.
#
#=head1 AUTHOR
#
#perlancar <perlancar@cpan.org>
#
#=head1 COPYRIGHT AND LICENSE
#
#This software is copyright (c) 2019, 2018, 2017, 2016, 2015, 2014, 2013, 2012 by perlancar@cpan.org.
#
#This is free software; you can redistribute it and/or modify it under
#the same terms as the Perl 5 programming language system itself.
#
#=cut
### Data/Dmp.pm ###
### no critic: Modules::ProhibitAutomaticExportation
#
#package Data::Dmp;
#
#our $AUTHORITY = 'cpan:PERLANCAR'; # AUTHORITY
#our $DATE = '2020-04-07'; # DATE
#our $DIST = 'Data-Dmp'; # DIST
#our $VERSION = '0.240'; # VERSION
#
#use 5.010001;
#use strict;
#use warnings;
#
#use Scalar::Util qw(looks_like_number blessed reftype refaddr);
#
#require Exporter;
#our @ISA = qw(Exporter);
#our @EXPORT = qw(dd dmp);
#our @EXPORT_OK = qw(dd_ellipsis dmp_ellipsis);
#
## for when dealing with circular refs
#our %_seen_refaddrs;
#our %_subscripts;
#our @_fixups;
#
#our $OPT_MAX_DUMP_LEN_BEFORE_ELLIPSIS = 70;
#our $OPT_PERL_VERSION = "5.010";
#our $OPT_REMOVE_PRAGMAS = 0;
#our $OPT_DEPARSE = 1;
#our $OPT_STRINGIFY_NUMBERS = 0;
#
## BEGIN COPY PASTE FROM Data::Dump
#my %esc = (
# "\a" => "\\a",
# "\b" => "\\b",
# "\t" => "\\t",
# "\n" => "\\n",
# "\f" => "\\f",
# "\r" => "\\r",
# "\e" => "\\e",
#);
#
## put a string value in double quotes
#sub _double_quote {
# local($_) = $_[0];
#
# # If there are many '"' we might want to use qq() instead
# s/([\\\"\@\$])/\\$1/g;
# return qq("$_") unless /[^\040-\176]/; # fast exit
#
# s/([\a\b\t\n\f\r\e])/$esc{$1}/g;
#
# # no need for 3 digits in escape for these
# s/([\0-\037])(?!\d)/sprintf('\\%o',ord($1))/eg;
#
# s/([\0-\037\177-\377])/sprintf('\\x%02X',ord($1))/eg;
# s/([^\040-\176])/sprintf('\\x{%X}',ord($1))/eg;
#
# return qq("$_");
#}
## END COPY PASTE FROM Data::Dump
#
#sub _dump_code {
# my $code = shift;
#
# state $deparse = do {
# require B::Deparse;
# B::Deparse->new("-l"); # -i option doesn't have any effect?
script/_zodiac-of view on Meta::CPAN
# $res = $OPT_DEPARSE ? _dump_code($val) : 'sub{"DUMMY"}';
# } else {
# die "Sorry, I can't dump $val (ref=$ref) yet";
# }
#
# $res = "bless($res,"._double_quote($class).")" if defined($class);
# $res;
#}
#
#our $_is_dd;
#our $_is_ellipsis;
#sub _dd_or_dmp {
# local %_seen_refaddrs;
# local %_subscripts;
# local @_fixups;
#
# my $res;
# if (@_ > 1) {
# $res = "(" . join(",", map {_dump($_, '')} @_) . ")";
# } else {
# $res = _dump($_[0], '');
# }
# if (@_fixups) {
# $res = "do{my\$a=$res;" . join("", @_fixups) . "\$a}";
# }
#
# if ($_is_ellipsis) {
# $res = substr($res, 0, $OPT_MAX_DUMP_LEN_BEFORE_ELLIPSIS) . '...'
# if length($res) > $OPT_MAX_DUMP_LEN_BEFORE_ELLIPSIS;
# }
#
# if ($_is_dd) {
# say $res;
# return wantarray() || @_ > 1 ? @_ : $_[0];
# } else {
# return $res;
# }
#}
#
#sub dd { local $_is_dd=1; _dd_or_dmp(@_) } # goto &sub doesn't work with local
#sub dmp { goto &_dd_or_dmp }
#
#sub dd_ellipsis { local $_is_dd=1; local $_is_ellipsis=1; _dd_or_dmp(@_) }
#sub dmp_ellipsis { local $_is_ellipsis=1; _dd_or_dmp(@_) }
#
#1;
## ABSTRACT: Dump Perl data structures as Perl code
#
#__END__
#
#=pod
#
#=encoding UTF-8
#
#=head1 NAME
#
#Data::Dmp - Dump Perl data structures as Perl code
#
#=head1 VERSION
#
#This document describes version 0.240 of Data::Dmp (from Perl distribution Data-Dmp), released on 2020-04-07.
#
#=head1 SYNOPSIS
#
# use Data::Dmp; # exports dd() and dmp()
# dd [1, 2, 3]; # prints "[1,2,3]"
# $a = dmp({a => 1}); # -> "{a=>1}"
#
#Print truncated dump (capped at L</$Data::Dmp::OPT_MAX_DUMP_LEN_BEFORE_ELLIPSIS>
#characters):
#
# use Data::Dmp qw(dd_ellipsis dmp_ellipsis);
# dd_ellipsis [1..100];
#
#=head1 DESCRIPTION
#
#Data::Dmp is a Perl dumper like L<Data::Dumper>. It's compact (only about 200
#lines of code long), starts fast and does not use any non-core modules except
#L<Regexp::Stringify> when dumping regexes. It produces compact single-line
#output (similar to L<Data::Dumper::Concise>). It roughly has the same speed as
#Data::Dumper (usually a bit faster for smaller structures) and faster than
#L<Data::Dump>, but does not offer the various formatting options. It supports
#dumping objects, regexes, circular structures, coderefs. Its code is first based
#on L<Data::Dump>: I removed all the parts that I don't need, particularly the
#pretty formatting stuffs) and added some features that I need like proper regex
#dumping and coderef deparsing.
#
#=head1 VARIABLES
#
#=head2 $Data::Dmp::OPT_PERL_VERSION
#
#String, default: 5.010.
#
#Set target Perl version. If you set this to, say C<5.010>, then the dumped code
#will keep compatibility with Perl 5.10.0. This is used in the following ways:
#
#=over
#
#=item * passed to L<Regexp::Stringify>
#
#=item * when dumping code references
#
#For example, in perls earlier than 5.016, feature.pm does not understand:
#
# no feature ':all';
#
#so we replace it with:
#
# no feature;
#
#=back
#
#=head2 $Data::Dmp::OPT_REMOVE_PRAGMAS
#
#Bool, default: 0.
#
#If set to 1, then pragmas at the start of coderef dump will be removed. Coderef
#dump is produced by L<B::Deparse> and is of the form like:
#
# sub { use feature 'current_sub', 'evalbytes', 'fc', 'say', 'state', 'switch', 'unicode_strings', 'unicode_eval'; $a <=> $b }
#
script/_zodiac-of view on Meta::CPAN
# $tree->find( $finder_subs{$_} )
# for qw( del_superfluous_concat del_last_semicolon_in_block separate_version shorten_var_names shorten_barewords );
# die $@ if $@;
#
# for my $name ( 'double_semicolon' ) {
# my $elements = $tree->find( $finder_subs{$name} );
# die $@ if !defined $elements;
# $_->delete for @{ $elements || [] };
# }
#
# return $tree->serialize . "\n";
#}
#
#sub tok { "PPI::Token::$_[0]" }
#
#sub _finder_subs {
# return (
# comments => sub { $_[1]->isa( tok 'Comment' ) },
#
# duplicate_whitespace => sub {
# my ( $top, $current ) = @_;
# return 0 if !$current->isa( tok 'Whitespace' );
#
# $current->set_content(' ') if 1 < length $current->content;
#
# return 0 if !$current->next_token;
# return 0 if !$current->next_token->isa( tok 'Whitespace' );
# return 1;
# },
#
# whitespace => sub {
# my ( $top, $current ) = @_;
# return 0 if !$current->isa( tok 'Whitespace' );
# my $prev = $current->previous_token;
# my $next = $current->next_token;
#
# return 1 if $prev->isa( tok 'Number' ) and $next->isa( tok 'Operator' ) and $next->content =~ /^\W/; # my $P
# return 1 if $prev->isa( tok 'Word' ) and $next->isa( tok 'Operator' ) and $next->content =~ /^\W/; # my $P
# return 1 if $prev->isa( tok 'Symbol' ) and $next->isa( tok 'Operator' ) and $next->content =~ /^\W/; # $VERSION = but not $v and
#
# return 1 if $prev->isa( tok 'Operator' ) and $next->isa( tok 'Quote::Single' ) and $next->content =~ /^\W/; # eq ''
# return 1 if $prev->isa( tok 'Operator' ) and $next->isa( tok 'Quote::Double' ) and $next->content =~ /^\W/; # eq ""
# return 1 if $prev->isa( tok 'Operator' ) and $next->isa( tok 'Symbol' ) and $next->content =~ /^\W/; # eq $v
# return 1 if $prev->isa( tok 'Operator' ) and $next->isa( tok 'Structure' ) and $next->content =~ /^\W/; # eq (
#
# return 1 if $prev->isa( tok 'Word' ) and $next->isa( tok 'Symbol' ); # my $P
# return 1 if $prev->isa( tok 'Word' ) and $next->isa( tok 'Structure' ); # sub {
# return 1 if $prev->isa( tok 'Word' ) and $next->isa( tok 'Quote::Double' ); # eval "
# return 1 if $prev->isa( tok 'Symbol' ) and $next->isa( tok 'Structure' ); # %a )
# return 1 if $prev->isa( tok 'ArrayIndex' ) and $next->isa( tok 'Operator' ); # $#_ ?
# return 1 if $prev->isa( tok 'Word' ) and $next->isa( tok 'Cast' ); # exists &$_
# return 0;
# },
#
# trailing_whitespace => sub {
# my ( $top, $current ) = @_;
# return 0 if !$current->isa( tok 'Whitespace' );
# my $prev = $current->previous_token;
#
# return 1 if $prev->isa( tok 'Structure' ); # ;[\n\s]
# return 1 if $prev->isa( tok 'Operator' ) and $prev->content =~ /\W$/; # = 0.24
# return 1 if $prev->isa( tok 'Quote::Double' ); # " .
# return 1 if $prev->isa( tok 'Quote::Single' ); # ' }
#
# return 0;
# },
#
# double_semicolon => sub {
# my ( $top, $current ) = @_;
# return 0 if !$current->isa( tok 'Structure' );
# return 0 if $current->content ne ';';
#
# my $prev = $current->previous_token;
#
# return 0 if !$prev->isa( tok 'Structure' );
# return 0 if $prev->content ne ';';
#
# return 1;
# },
#
# del_last_semicolon_in_block => sub {
# my ( $top, $current ) = @_;
# return 0 if !$current->isa( 'PPI::Structure::Block' );
#
# my $last = $current->last_token;
#
# return 0 if !$last->isa( tok 'Structure' );
# return 0 if $last->content ne '}';
#
# my $maybe_semi = $last->previous_token;
#
# return 0 if !$maybe_semi->isa( tok 'Structure' );
# return 0 if $maybe_semi->content ne ';';
#
# $maybe_semi->delete;
#
# return 1;
# },
#
# del_superfluous_concat => sub {
# my ( $top, $current ) = @_;
# return 0 if !$current->isa( tok 'Operator' );
#
# my $prev = $current->previous_token;
# my $next = $current->next_token;
#
# return 0 if $current->content ne '.';
# return 0 if !$prev->isa( tok 'Quote::Double' );
# return 0 if !$next->isa( tok 'Quote::Double' );
#
# $current->delete;
# $prev->set_content( $prev->{separator} . $prev->string . $next->string . $prev->{separator} );
# $next->delete;
#
# return 1;
# },
#
# separate_version => sub {
# my ( $top, $current ) = @_;
# return 0 if !$current->isa( 'PPI::Statement' );
#
( run in 3.405 seconds using v1.01-cache-2.11-cpan-d8267643d1d )