]> git.donarmstrong.com Git - perltidy.git/commitdiff
bump version to 20211029.01 20211029.01
authorSteve Hancock <perltidy@users.sourceforge.net>
Sat, 20 Nov 2021 15:43:20 +0000 (07:43 -0800)
committerSteve Hancock <perltidy@users.sourceforge.net>
Sat, 20 Nov 2021 15:43:20 +0000 (07:43 -0800)
21 files changed:
CHANGES.md
bin/perltidy
lib/Perl/Tidy.pm
lib/Perl/Tidy.pod
lib/Perl/Tidy/Debugger.pm
lib/Perl/Tidy/DevNull.pm
lib/Perl/Tidy/Diagnostics.pm
lib/Perl/Tidy/FileWriter.pm
lib/Perl/Tidy/Formatter.pm
lib/Perl/Tidy/HtmlWriter.pm
lib/Perl/Tidy/IOScalar.pm
lib/Perl/Tidy/IOScalarArray.pm
lib/Perl/Tidy/IndentationItem.pm
lib/Perl/Tidy/LineBuffer.pm
lib/Perl/Tidy/LineSink.pm
lib/Perl/Tidy/LineSource.pm
lib/Perl/Tidy/Logger.pm
lib/Perl/Tidy/Tokenizer.pm
lib/Perl/Tidy/VerticalAligner.pm
lib/Perl/Tidy/VerticalAligner/Alignment.pm
lib/Perl/Tidy/VerticalAligner/Line.pm

index 34541c4a5200672f092543ccc3d747723871f0d4..b8d8deb36c079b498d59da978f105c802df740a3 100644 (file)
@@ -1,9 +1,20 @@
 # Perltidy Change Log
 
-## 2021 10 29 xx
+## 2021 10 29.01
 
     - The coding for the -lp flag has been rewritten to avoid some problems
-      and limitations.
+      and limitations.  The new coding allows the -lp indentation style to
+      mix smoothly with the standard indentation in a single file.  Some problems
+      where -lp and -xci flags were not working well together have been fixed, such
+      as happened in issue rt140025.
+
+    - A new flag -xlp has been added which can be set to avoid most of the
+      limitations of the -lp flag regarding side comments, blank lines, and
+      code blocks.  This is off by default to avoid changing existing coding,
+      so this flag has to be set to turn this feature on.  [Documentation still
+      needs to be written].  It will be included in the next release to CPAN,
+      but some details regarding how it handles very long lines may change before
+      the final release to CPAN.  This fixes issues git #64 and git #74.
 
 ## 2021 10 29
 
index 0ce77be67d3eb1d392c2865af4fcca648cdc04fe..a955a143b705bada3aaf5947a6565467feb411f9 100755 (executable)
@@ -4898,7 +4898,7 @@ The perltidy binary uses the Perl::Tidy module and is installed when that module
 
 =head1 VERSION
 
-This man page documents perltidy version 20211029
+This man page documents perltidy version 20211029.01
 
 =head1 BUG REPORTS
 
index 71965ba60a6a905a5573fdf9106221f7aa064ec4..7b554026ed2c5ed41c8503e4037c18bc8f6d9627 100644 (file)
@@ -110,7 +110,7 @@ BEGIN {
     # Release version must be bumped, and it is probably past time for a
     # release anyway.
 
-    $VERSION = '20211029';
+    $VERSION = '20211029.01';
 }
 
 sub DESTROY {
index 50b512b950c80d0e3543c409116b995b512588d4..762a8760f106d72c60c408c75f30dfc7b585fdfe 100644 (file)
@@ -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 20211029
+This man page documents Perl::Tidy version 20211029.01
 
 =head1 LICENSE
 
index 691c9b9e35ef3862e3e16d7a9132c83f7b0a5438..6992143f4c5c635c04a6130de5e91dae93414cd4 100644 (file)
@@ -7,7 +7,7 @@
 package Perl::Tidy::Debugger;
 use strict;
 use warnings;
-our $VERSION = '20211029';
+our $VERSION = '20211029.01';
 
 sub new {
 
index f9a14b2ee15955d5d5e749b774a6a3dda8c35493..59e6b1f4041045a73a66996eb52112a9d78cf6b9 100644 (file)
@@ -7,7 +7,7 @@
 package Perl::Tidy::DevNull;
 use strict;
 use warnings;
-our $VERSION = '20211029';
+our $VERSION = '20211029.01';
 sub new   { my $self = shift; return bless {}, $self }
 sub print { return }
 sub close { return }
index e76182626f2047c68e7c4e89c9bdc043952e3daf..f3e9b4993fbadcf068fdf5ecaffeb9bc5fcd52de 100644 (file)
@@ -20,7 +20,7 @@
 package Perl::Tidy::Diagnostics;
 use strict;
 use warnings;
-our $VERSION = '20211029';
+our $VERSION = '20211029.01';
 
 sub AUTOLOAD {
 
index 0f124b4d6f26a2f576995cb292a89dbc16324bc2..031cc6fae6214c408df305a8fd81ea04a60161fb 100644 (file)
@@ -7,7 +7,7 @@
 package Perl::Tidy::FileWriter;
 use strict;
 use warnings;
-our $VERSION = '20211029';
+our $VERSION = '20211029.01';
 
 use constant DEVEL_MODE => 0;
 
index a96d2f51ac157679381b75e1910137406363c3eb..756c94675f5087cb3e22d17ed9c3317e264b4b69 100644 (file)
@@ -49,7 +49,7 @@ use constant DEVEL_MODE => 0;
 { #<<< A non-indenting brace to contain all lexical variables
 
 use Carp;
-our $VERSION = '20211029';
+our $VERSION = '20211029.01';
 
 # The Tokenizer will be loaded with the Formatter
 ##use Perl::Tidy::Tokenizer;    # for is_keyword()
@@ -709,7 +709,7 @@ sub new {
     initialize_undo_ci();
     initialize_process_line_of_CODE();
     initialize_grind_batch_of_CODE();
-    initialize_adjusted_indentation();
+    initialize_final_indentation_adjustment();
     initialize_postponed_breakpoint();
     initialize_batch_variables();
     initialize_forced_breakpoint_vars();
@@ -9728,7 +9728,7 @@ sub break_before_list_opening_containers {
         next unless ($ci_flag);
 
         # -bbxi=1: This option removes ci and is handled in
-        # later sub set_adjusted_indentation
+        # later sub final_indentation_adjustment
         if ( $ci_flag == 1 ) {
             $rwant_reduced_ci->{$seqno} = 1;
             next;
@@ -14999,7 +14999,7 @@ sub break_equals {
                     # trailing clause will be far to the right.
                     #
                     # The logic here is synchronized with the logic in sub
-                    # sub set_adjusted_indentation, which actually does
+                    # sub final_indentation_adjustment, which actually does
                     # the outdenting.
                     #
                     $skip_Section_3 ||= $this_line_is_semicolon_terminated
@@ -15050,7 +15050,7 @@ sub break_equals {
                     #       #handle error
                     #     };
                     # The alternative, for uncuddled style, is to create
-                    # a patch in set_adjusted_indentation which undoes
+                    # a patch in final_indentation_adjustment which undoes
                     # the indentation of a leading line like 'or do {'.
                     # This doesn't work well with -icb through
                     if (
@@ -20602,7 +20602,7 @@ sub convey_batch_to_vertical_aligner {
         my $Kend_code =
           $batch_CODE_type && $batch_CODE_type ne 'VER' ? undef : $Kend;
 
-        #  $ljump is a level jump needed by 'sub set_adjusted_indentation'
+        #  $ljump is a level jump needed by 'sub final_indentation_adjustment'
         my $ljump = 0;
 
         # Get some vars on line [n+1], if any:
@@ -20668,7 +20668,7 @@ EOM
         # --------------------------------------
         my ( $indentation, $lev, $level_end, $terminal_type,
             $terminal_block_type, $is_semicolon_terminated, $is_outdented_line )
-          = $self->set_adjusted_indentation( $ibeg, $iend, $rfields,
+          = $self->final_indentation_adjustment( $ibeg, $iend, $rfields,
             $rpatterns,         $ri_first, $ri_last,
             $rindentation_list, $ljump,    $starting_in_quote,
             $is_static_block_comment, );
@@ -20963,7 +20963,7 @@ EOM
     } ## end of loop to output each line
 
     # remember indentation of lines containing opening containers for
-    # later use by sub set_adjusted_indentation
+    # later use by sub final_indentation_adjustment
     $self->save_opening_indentation( $ri_first, $ri_last, $rindentation_list )
       if ( !$is_block_comment );
 
@@ -21705,7 +21705,7 @@ sub get_seqno {
             # SECTION 2: Undo ci at cuddled blocks
             #-------------------------------------
 
-            # Note that sub set_adjusted_indentation will be called later to
+            # Note that sub final_indentation_adjustment will be called later to
             # actually do this, but for now we will tentatively mark cuddled
             # lines with ci=0 so that the the -xci loop which follows will be
             # correct at cuddles.
@@ -22920,25 +22920,27 @@ sub make_paren_name {
     return $name;
 }
 
-{    ## begin closure set_adjusted_indentation
+{    ## begin closure final_indentation_adjustment
 
     my ( $last_indentation_written, $last_unadjusted_indentation,
         $last_leading_token );
 
-    sub initialize_adjusted_indentation {
+    sub initialize_final_indentation_adjustment {
         $last_indentation_written    = 0;
         $last_unadjusted_indentation = 0;
         $last_leading_token          = "";
         return;
     }
 
-    sub set_adjusted_indentation {
+    sub final_indentation_adjustment {
 
-        # This routine has the final say regarding the actual indentation of
-        # a line.  It starts with the basic indentation which has been
-        # defined for the leading token, and then takes into account any
-        # options that the user has set regarding special indenting and
-        # outdenting.
+        #--------------------------------------------------------------------
+        # This routine sets the final indentation of a line in the Formatter.
+        #--------------------------------------------------------------------
+
+        # It starts with the basic indentation which has been defined for the
+        # leading token, and then takes into account any options that the user
+        # has set regarding special indenting and outdenting.
 
         # This routine has to resolve a number of complex interacting issues,
         # including:
@@ -23682,7 +23684,7 @@ sub make_paren_name {
             $terminal_block_type, $is_semicolon_terminated,
             $is_outdented_line );
     }
-} ## end closure set_adjusted_indentation
+} ## end closure final_indentation_adjustment
 
 sub get_opening_indentation {
 
index 6f55c517261604482594e7f3fa9265ae614b766a..6a8169061ab04c8202759781600bc36720901179 100644 (file)
@@ -7,7 +7,7 @@
 package Perl::Tidy::HtmlWriter;
 use strict;
 use warnings;
-our $VERSION = '20211029';
+our $VERSION = '20211029.01';
 
 use File::Basename;
 
index 3d5adae48ca6be262fbf0103ecf875fd72998e25..314bd165deb13f11bffa40d473efd6877584d788 100644 (file)
@@ -10,7 +10,7 @@ package Perl::Tidy::IOScalar;
 use strict;
 use warnings;
 use Carp;
-our $VERSION = '20211029';
+our $VERSION = '20211029.01';
 
 sub AUTOLOAD {
 
index 1eea51d0f811af97e62bcc56aaeac95beb2eb509..0421a1afd6de3eaf8ff88be1fb3553cabc92b0c2 100644 (file)
@@ -14,7 +14,7 @@ package Perl::Tidy::IOScalarArray;
 use strict;
 use warnings;
 use Carp;
-our $VERSION = '20211029';
+our $VERSION = '20211029.01';
 
 sub AUTOLOAD {
 
index 86cbf4c5f9dfcccb19ab9f3df0fd882ad4c5d7ec..aee0a7bca32366f4606b179c968a9911ec2da7e0 100644 (file)
@@ -8,7 +8,7 @@
 package Perl::Tidy::IndentationItem;
 use strict;
 use warnings;
-our $VERSION = '20211029';
+our $VERSION = '20211029.01';
 
 BEGIN {
 
index 29d7dd2ff9400ae7118cab5d762ceabcafaabbc8..15d0021e787d66c3ecb57af6cebfe8559348bd6f 100644 (file)
@@ -12,7 +12,7 @@
 package Perl::Tidy::LineBuffer;
 use strict;
 use warnings;
-our $VERSION = '20211029';
+our $VERSION = '20211029.01';
 
 sub AUTOLOAD {
 
index 7825c2734b123db48637a0a4e77768e2652da6bc..72f19d50df211f63bf9c6a0aa72960daec10b0d5 100644 (file)
@@ -8,7 +8,7 @@
 package Perl::Tidy::LineSink;
 use strict;
 use warnings;
-our $VERSION = '20211029';
+our $VERSION = '20211029.01';
 
 sub AUTOLOAD {
 
index 91987c719360e461c721d37bb7bda814a4889b5e..68c6f79b67f318f2d00ac0351dcd9741edf10bf4 100644 (file)
@@ -8,7 +8,7 @@
 package Perl::Tidy::LineSource;
 use strict;
 use warnings;
-our $VERSION = '20211029';
+our $VERSION = '20211029.01';
 
 sub AUTOLOAD {
 
index 91c52be5d4f3819687ef6846135ad8353d1245e0..dd8d407bde5966bebb984be181f52c4f97c1c566 100644 (file)
@@ -7,7 +7,7 @@
 package Perl::Tidy::Logger;
 use strict;
 use warnings;
-our $VERSION = '20211029';
+our $VERSION = '20211029.01';
 
 sub AUTOLOAD {
 
index 73739d0c47ef7acacf9abe593410cf72acf11180..8ae4b7e6ba69724c839d4990ea9fde830f68b86e 100644 (file)
@@ -21,7 +21,7 @@
 package Perl::Tidy::Tokenizer;
 use strict;
 use warnings;
-our $VERSION = '20211029';
+our $VERSION = '20211029.01';
 
 # this can be turned on for extra checking during development
 use constant DEVEL_MODE => 0;
index 1864b7e02e138712e94a945a39be7fa7629f18eb..f3c385790beda007b1d881bf22bffb7349cd1b00 100644 (file)
@@ -2,7 +2,7 @@ package Perl::Tidy::VerticalAligner;
 use strict;
 use warnings;
 use Carp;
-our $VERSION = '20211029';
+our $VERSION = '20211029.01';
 use Perl::Tidy::VerticalAligner::Alignment;
 use Perl::Tidy::VerticalAligner::Line;
 
index 0d2e6d9020791510626a0d5554f36b874b27d324..f2cac97681755f4f4861bb18e3ce129229b55176 100644 (file)
@@ -10,7 +10,7 @@ use warnings;
 
 { #<<< A non-indenting brace
 
-our $VERSION = '20211029';
+our $VERSION = '20211029.01';
 
 BEGIN {
 
index 68f9e0e8995689435bf614d8d16ab6b40abba6b1..caae9d78d10d7791e702b202f56e153a9c7262c0 100644 (file)
@@ -8,7 +8,7 @@
 package Perl::Tidy::VerticalAligner::Line;
 use strict;
 use warnings;
-our $VERSION = '20211029';
+our $VERSION = '20211029.01';
 
 BEGIN {