]> git.donarmstrong.com Git - perltidy.git/commitdiff
fix b1427
authorSteve Hancock <perltidy@users.sourceforge.net>
Sun, 27 Nov 2022 03:24:54 +0000 (19:24 -0800)
committerSteve Hancock <perltidy@users.sourceforge.net>
Sun, 27 Nov 2022 03:24:54 +0000 (19:24 -0800)
dev-bin/run_convergence_tests.pl.data
lib/Perl/Tidy/Formatter.pm

index 05994e4da17ae689a35061f79db1e5911906ae22..09d4813ba97943020d8b2a782ea182ce45275c03 100644 (file)
@@ -10988,6 +10988,25 @@ my$sem=sub
 --variable-maximum-line-length
 --want-trailing-commas='m'
 
+==> b1427.in <==
+print join( "\n",
+          @intersection, ),
+  "\n";
+
+print join( "\n",
+            @intersection
+  ),
+  "\n";
+
+==> b1427.par <==
+--add-trailing-commas
+--delete-trailing-commas
+--extended-line-up-parentheses
+--indent-columns=0
+--maximum-fields-per-table=80
+--maximum-line-length=27
+--want-trailing-commas='b'
+
 ==> b1428.in <==
          is(
               grep ( { $_->{branchcode} eq 'MYLIBRARY' and $_->{selected} == 1 }
index 84344bd55b465d0d9494d806cb8d5ba0669ed7cd..8eb583e17cfcc8be115ed9d442f921401b9511bd 100644 (file)
@@ -22015,6 +22015,13 @@ EOM
             $number_of_fields = $number_of_fields_best;
         }
 
+        # fix b1427
+        elsif ($number_of_fields_best > 1
+            && $number_of_fields_best > $number_of_fields_max )
+        {
+            $number_of_fields_best = $number_of_fields_max;
+        }
+
         # If we are crowded and the -lp option is being used, try
         # to undo some indentation
         if (