From: Steve Hancock Date: Mon, 12 Oct 2020 00:17:15 +0000 (-0700) Subject: bump version to .02 X-Git-Tag: 20201001.02^0 X-Git-Url: https://git.donarmstrong.com/?a=commitdiff_plain;h=6e630401214221657855f3bebd1d4b03ff408c0c;p=perltidy.git bump version to .02 --- diff --git a/CHANGES.md b/CHANGES.md index 60e04b7c..ac51718f 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -1,6 +1,6 @@ # Perltidy Change Log -## 2020 10 01.01 +## 2020 10 01.02 - Add flag -xci, --extended-continuation-indentation, regarding issue git #28 diff --git a/bin/perltidy b/bin/perltidy index 13d56ffc..4c4d1c2c 100755 --- a/bin/perltidy +++ b/bin/perltidy @@ -4352,7 +4352,7 @@ The perltidy binary uses the Perl::Tidy module and is installed when that module =head1 VERSION -This man page documents perltidy version 20201001.01 +This man page documents perltidy version 20201001.02 =head1 BUG REPORTS diff --git a/lib/Perl/Tidy.pm b/lib/Perl/Tidy.pm index acff7509..3a8c35e9 100644 --- a/lib/Perl/Tidy.pm +++ b/lib/Perl/Tidy.pm @@ -107,7 +107,7 @@ BEGIN { # Release version must be bumped, and it is probably past time for a # release anyway. - $VERSION = '20201001.01'; + $VERSION = '20201001.02'; } sub DESTROY { diff --git a/lib/Perl/Tidy.pod b/lib/Perl/Tidy.pod index 7365238b..b4a27998 100644 --- a/lib/Perl/Tidy.pod +++ b/lib/Perl/Tidy.pod @@ -432,7 +432,7 @@ The module 'Perl::Tidy' comes with a binary 'perltidy' which is installed when t =head1 VERSION -This man page documents Perl::Tidy version 20201001.01 +This man page documents Perl::Tidy version 20201001.02 =head1 LICENSE diff --git a/lib/Perl/Tidy/Debugger.pm b/lib/Perl/Tidy/Debugger.pm index 3362de59..007538f2 100644 --- a/lib/Perl/Tidy/Debugger.pm +++ b/lib/Perl/Tidy/Debugger.pm @@ -7,7 +7,7 @@ package Perl::Tidy::Debugger; use strict; use warnings; -our $VERSION = '20201001.01'; +our $VERSION = '20201001.02'; sub new { diff --git a/lib/Perl/Tidy/DevNull.pm b/lib/Perl/Tidy/DevNull.pm index a17fe974..c0bd13bf 100644 --- a/lib/Perl/Tidy/DevNull.pm +++ b/lib/Perl/Tidy/DevNull.pm @@ -7,7 +7,7 @@ package Perl::Tidy::DevNull; use strict; use warnings; -our $VERSION = '20201001.01'; +our $VERSION = '20201001.02'; sub new { my $self = shift; return bless {}, $self } sub print { return } sub close { return } diff --git a/lib/Perl/Tidy/Diagnostics.pm b/lib/Perl/Tidy/Diagnostics.pm index 901d33c2..6b9dd50c 100644 --- a/lib/Perl/Tidy/Diagnostics.pm +++ b/lib/Perl/Tidy/Diagnostics.pm @@ -20,7 +20,7 @@ package Perl::Tidy::Diagnostics; use strict; use warnings; -our $VERSION = '20201001.01'; +our $VERSION = '20201001.02'; sub AUTOLOAD { @@ -28,7 +28,7 @@ sub AUTOLOAD { # some diagnostic information. This sub should never be called # except for a programming error. our $AUTOLOAD; - return if ( $AUTOLOAD =~/\bDESTROY$/ ); + return if ( $AUTOLOAD =~ /\bDESTROY$/ ); my ( $pkg, $fname, $lno ) = caller(); print STDERR < 0; { #<<< A non-indenting brace to contain all lexical variables use Carp; -our $VERSION = '20201001.01'; +our $VERSION = '20201001.02'; # The Tokenizer will be loaded with the Formatter ##use Perl::Tidy::Tokenizer; # for is_keyword() @@ -6893,6 +6893,14 @@ sub extended_ci { my $KK = $KNEXT; $KNEXT = $rLL->[$KNEXT]->[_KNEXT_SEQ_ITEM_]; + my $seqno = $rLL->[$KK]->[_TYPE_SEQUENCE_]; + my $K_opening = $K_opening_container->{$seqno}; + + # see if we have reached the end of the current controlling container + if ( $seqno_top && $seqno == $seqno_top ) { + $seqno_top = pop @seqno_stack; + } + # Patch to fix some block types... # Certain block types arrive from the tokenizer without CI but should # have it for this option. These include anonymous subs and @@ -6900,14 +6908,10 @@ sub extended_ci { my $block_type = $rLL->[$KK]->[_BLOCK_TYPE_]; if ( $block_type && $is_block_with_ci{$block_type} ) { $rLL->[$KK]->[_CI_LEVEL_] = 1; - } - - # see if we have reached the end of the current controlling container - my $seqno = $rLL->[$KK]->[_TYPE_SEQUENCE_]; - if ( $seqno_top && $seqno == $seqno_top ) { - ## $rLL->[$KK]->[_CI_LEVEL_] = 1; ## should not be necessary - $seqno_top = pop @seqno_stack; - next; + if ($seqno_top) { + $rseqno_which_extended_ci->{$KK} = $seqno_top; + $ris_seqno_controlling_ci->{$seqno_top}++; + } } # If this does not have ci, update ci if necessary and continue looking @@ -6921,7 +6925,6 @@ sub extended_ci { } # We are looking for opening container tokens with ci - my $K_opening = $K_opening_container->{$seqno}; next unless ( defined($K_opening) && $KK == $K_opening ); # Make sure there is a corresponding closing container @@ -17795,11 +17798,11 @@ sub make_paren_name { # options that the user has set regarding special indenting and # outdenting. - # This routine is mainly concerned with outdenting closing tokens but - # has become a 'catchall' for a variety of special problems involving - # ci. Note that there is some overlap with the functions of sub - # undo_ci, which was processed earlier, so care has to be taken to keep - # them coordinated. + # This routine is mainly concerned with outdenting closing tokens but + # has become a 'catchall' for a variety of special problems involving + # ci. Note that there is some overlap with the functions of sub + # undo_ci, which was processed earlier, so care has to be taken to keep + # them coordinated. my ( $self, $ibeg, @@ -18004,10 +18007,8 @@ sub make_paren_name { # and do not undo ci if it was set by the -xci option $adjust_indentation = 1 - if ( - $level_next < $lev - && !$rseqno_which_extended_ci->{$K_beg} - ); + if ( $level_next < $lev + && !$rseqno_which_extended_ci->{$K_beg} ); } # Patch for RT #96101, in which closing brace of anonymous subs diff --git a/lib/Perl/Tidy/HtmlWriter.pm b/lib/Perl/Tidy/HtmlWriter.pm index 2fe50ad8..f745f3d9 100644 --- a/lib/Perl/Tidy/HtmlWriter.pm +++ b/lib/Perl/Tidy/HtmlWriter.pm @@ -7,7 +7,7 @@ package Perl::Tidy::HtmlWriter; use strict; use warnings; -our $VERSION = '20201001.01'; +our $VERSION = '20201001.02'; use File::Basename; @@ -44,7 +44,7 @@ sub AUTOLOAD { # some diagnostic information. This sub should never be called # except for a programming error. our $AUTOLOAD; - return if ( $AUTOLOAD =~/\bDESTROY$/ ); + return if ( $AUTOLOAD =~ /\bDESTROY$/ ); my ( $pkg, $fname, $lno ) = caller(); print STDERR < $tokenizer_self->[_maximum_level_] ) { - $tokenizer_self->[ _maximum_level_ ] = $level_in_tokenizer; + $tokenizer_self->[_maximum_level_] = $level_in_tokenizer; } if ($forced_indentation_flag) { diff --git a/lib/Perl/Tidy/VerticalAligner.pm b/lib/Perl/Tidy/VerticalAligner.pm index 05ba52d4..79d94ecf 100644 --- a/lib/Perl/Tidy/VerticalAligner.pm +++ b/lib/Perl/Tidy/VerticalAligner.pm @@ -1,7 +1,7 @@ package Perl::Tidy::VerticalAligner; use strict; use warnings; -our $VERSION = '20201001.01'; +our $VERSION = '20201001.02'; use Perl::Tidy::VerticalAligner::Alignment; use Perl::Tidy::VerticalAligner::Line; @@ -60,7 +60,7 @@ sub AUTOLOAD { # some diagnostic information. This sub should never be called # except for a programming error. our $AUTOLOAD; - return if ( $AUTOLOAD =~/\bDESTROY$/ ); + return if ( $AUTOLOAD =~ /\bDESTROY$/ ); my ( $pkg, $fname, $lno ) = caller(); print STDERR <group_line_count() + diff --git a/lib/Perl/Tidy/VerticalAligner/Alignment.pm b/lib/Perl/Tidy/VerticalAligner/Alignment.pm index 3d79829f..08afc517 100644 --- a/lib/Perl/Tidy/VerticalAligner/Alignment.pm +++ b/lib/Perl/Tidy/VerticalAligner/Alignment.pm @@ -10,7 +10,7 @@ use warnings; { #<<< A non-indenting brace -our $VERSION = '20201001.01'; +our $VERSION = '20201001.02'; # _column_ # the current column number # _starting_column_ # column number when created diff --git a/lib/Perl/Tidy/VerticalAligner/Line.pm b/lib/Perl/Tidy/VerticalAligner/Line.pm index f35ecf3b..800ac892 100644 --- a/lib/Perl/Tidy/VerticalAligner/Line.pm +++ b/lib/Perl/Tidy/VerticalAligner/Line.pm @@ -8,7 +8,7 @@ package Perl::Tidy::VerticalAligner::Line; use strict; use warnings; -our $VERSION = '20201001.01'; +our $VERSION = '20201001.02'; BEGIN { my $i = 0; @@ -77,7 +77,7 @@ BEGIN { # some diagnostic information. This sub should never be called # except for a programming error. our $AUTOLOAD; - return if ( $AUTOLOAD =~/\bDESTROY$/ ); + return if ( $AUTOLOAD =~ /\bDESTROY$/ ); my ( $pkg, $fname, $lno ) = caller(); print STDERR <