]> git.donarmstrong.com Git - perltidy.git/commitdiff
fix b1465 20230912.13
authorSteve Hancock <perltidy@users.sourceforge.net>
Mon, 22 Jan 2024 02:27:47 +0000 (18:27 -0800)
committerSteve Hancock <perltidy@users.sourceforge.net>
Mon, 22 Jan 2024 02:27:47 +0000 (18:27 -0800)
dev-bin/run_convergence_tests.pl.data
dev-bin/run_convergence_tests.pl.expect
lib/Perl/Tidy/Formatter.pm

index 31a9c41e138a40dc1033cb658c0eda354f27aafe..5504e62ead2af910c634b1039cb222797a61e34d 100644 (file)
@@ -11899,6 +11899,42 @@ while (
 --keyword-group-blanks-size='2.8'
 --keyword-group-blanks-before=2
 
+==> b1465.in <==
+# See initialize_lp_*
+
+my @pics =
+         grep ( -f "$dir/$_"
+                  && -s "$dir/$_"
+                  &&              # Not zero byte file
+                  !-f "$dir/$_$NO_ALBUM"
+                  &&              # Don't show these
+                  !/\Q$NOT_IMG\E$/
+                  &&              # The not_img files themselves
+                  !/\Q$NO_ALBUM\E$/
+                  &&              # The not_img files themselves
+                  !/\.txt$/ &&    # Per image captions
+                  !/\.htaccess$/
+                  &&              # httpd security files
+                  !/~$/ &&        # Emacs backup files
+                  $_ ne
+"$opt->{'index'}$HTML"
+                  &&                 # Index html
+                  $_ ne $HEADER &&   # Header/footer
+                  $_ ne $FOOTER
+                  && $_ ne
+                  $opt->{'captions'}
+         ,                           # Captions file
+         @dir );
+
+
+==> b1465.par <==
+--maximum-line-length=29
+--indent-columns=9
+--continuation-indentation=9
+--variable-maximum-line-length
+--extended-line-up-parentheses
+--ignore-side-comment-lengths
+
 ==> b148.in <==
 # state 1
 @yydgoto=(
index 7e18b398e4050b9bc9f7946f17327177d5824461..e7ebfbebd18547dcf97de8dc8b16e3ec89f627f8 100644 (file)
@@ -7807,11 +7807,15 @@ my %distance_pref =
 
 
 ==> b1453 <==
-my $foo = decode_json( {
-      foo => 'bar' } );
+my $foo =
+          decode_json( {
+              foo => 'bar' }
+          );
 
-my $foo = decode_json( {
-      foo => 'bar' } );
+my $foo =
+          decode_json( {
+              foo => 'bar' }
+          );
 
 ==> b1454 <==
 my $red_color =
@@ -8047,6 +8051,34 @@ while ( $^O !~ /Win32/ and
     sleep $config->{delay};
 }
 
+==> b1465 <==
+# See initialize_lp_*
+
+my @pics =
+         grep ( -f "$dir/$_"
+                  && -s "$dir/$_"
+                  &&              # Not zero byte file
+                  !-f "$dir/$_$NO_ALBUM"
+                  &&              # Don't show these
+                  !/\Q$NOT_IMG\E$/
+                  &&              # The not_img files themselves
+                  !/\Q$NO_ALBUM\E$/
+                  &&              # The not_img files themselves
+                  !/\.txt$/ &&    # Per image captions
+                  !/\.htaccess$/
+                  &&              # httpd security files
+                  !/~$/ &&        # Emacs backup files
+                  $_ ne
+"$opt->{'index'}$HTML"
+                  &&                 # Index html
+                  $_ ne $HEADER &&   # Header/footer
+                  $_ ne $FOOTER
+                  && $_ ne
+                  $opt->{'captions'}
+         ,                           # Captions file
+         @dir );
+
+
 ==> b148 <==
 # state 1
 @yydgoto=(
index aff0260fc4b6923b1c8f409dff14237cae91c9c0..711c90c8f3a0678b5e8d998f35a676db55235df2 100644 (file)
@@ -28023,6 +28023,11 @@ sub get_available_spaces_to_go {
             $rOpts_extended_line_up_parentheses = 0;
         }
 
+        # fix for b1465: -vmll adds stress for -xlp
+        if ( $high_stress_level <= 2 && $rOpts_variable_maximum_line_length ) {
+            $rOpts_extended_line_up_parentheses = 0;
+        }
+
         $rLP = [];
 
         # initialize the leading whitespace stack to negative levels