]> git.donarmstrong.com Git - perltidy.git/commitdiff
fix unusual blinker related to large -ci and -mft=n
authorSteve Hancock <perltidy@users.sourceforge.net>
Tue, 12 Jan 2021 23:50:21 +0000 (15:50 -0800)
committerSteve Hancock <perltidy@users.sourceforge.net>
Tue, 12 Jan 2021 23:50:21 +0000 (15:50 -0800)
lib/Perl/Tidy/Formatter.pm
local-docs/BugLog.pod
t/snippets/README.md

index 6bc334129d56579118af08f20b1423f8aa4cd93c..ddf2d8181cc579fa07efcf77ac476b4355498a97 100644 (file)
@@ -10651,6 +10651,8 @@ EOM
                 || (
                     $comma_count_in_batch
                     && (   $rOpts_maximum_fields_per_table > 0
+                        && $rOpts_maximum_fields_per_table <=
+                        $comma_count_in_batch
                         || $rOpts_comma_arrow_breakpoints == 0 )
                 )
 
index 0fe5c94d41dd7ee2f0812f7e3bb4f443d5fec262..29de28bc4c264f603aa6f12ebcc4d5fef1b26ebd 100644 (file)
@@ -2,6 +2,27 @@
 
 =over 4
 
+=item B<Fixed unusual blinker>
+
+The following blinker was found in random testing. The following statement 
+(with @j starting at level 0)
+
+    @j = ( $x, $y, $z );
+
+run with the following profile
+
+    --indent-columns=5
+    --continuation-indentation=7
+    --maximum-line-length=20
+    --break-before-paren-and-indent=2
+    --break-before-paren=2
+    --maximum-fields-per-table=4
+
+caused an oscillation between two states.  An unusual feature which contributed
+to the problem is the very large ci value. This is fixed in a patch made 12 Jan
+2021.
+
+
 =item B<Improve indentation of multiline qw quotes when -xci flag is set>
 
 The indentation of multiline qw quotes runs into problems when there is nesting,
index 6780210e6bc302a0930dce7e2ec3287afa194ef7..28fd1cd78ed463574ca5e96b735af838728cda12 100644 (file)
@@ -203,3 +203,9 @@ To update the list of covered parameters, run
 ```
   make_coverage_report.pl
 ```
+
+This shows which parameters are included in test cases.  Most are covered, 
+and when new parameters are added there should also be corresponding test
+cases added. But a problem is that perltidy has so many parameters that it is
+not possible to write enough tests to test all combinations.  This problem
+is addressed with the random testing scripts in the ```git/dev-bin``` directory.