From a93dcac3440754ebf25035fe98cc55b958b3ce7d Mon Sep 17 00:00:00 2001 From: Steve Hancock Date: Thu, 11 Nov 2021 17:42:00 -0800 Subject: [PATCH] fix b1244, do not start -lp under stress --- dev-bin/run_convergence_tests.pl.data | 57 +++++++++++++++++++++++++++ lib/Perl/Tidy/Formatter.pm | 5 +++ 2 files changed, 62 insertions(+) diff --git a/dev-bin/run_convergence_tests.pl.data b/dev-bin/run_convergence_tests.pl.data index 0f4373d4..4407e908 100644 --- a/dev-bin/run_convergence_tests.pl.data +++ b/dev-bin/run_convergence_tests.pl.data @@ -8097,6 +8097,63 @@ WriteMakefile( --variable-maximum-line-length --weld-nested-containers +==> b1244.in <== +# S1 + @NVNN_w2 = + ( Lampoons, Launders, + Leapfrogs, Leaps, + Learns, Legitimizes, + Levels, Levitates, + Liberates, Lightens, + Likes, Liquidates, + Loathes, Loosens, + Loves, Lubricates, + ); + + @NNVN_w3 = + ( Unclutters, + Unfetters, + Unifies, Unites, + Unseats, Upgrades, + Upstages, Uses, + Usurps, ); +# S2 + @NVNN_w2 = ( Lampoons, + Launders, + Leapfrogs, + Leaps, + Learns, + Legitimizes, + Levels, + Levitates, + Liberates, + Lightens, + Likes, + Liquidates, + Loathes, + Loosens, + Loves, + Lubricates, + ); + + @NNVN_w3 = ( Unclutters, + Unfetters, + Unifies, + Unites, + Unseats, + Upgrades, + Upstages, + Uses, + Usurps, + ); + +==> b1244.par <== +--continuation-indentation=8 +--ignore-old-breakpoints +--indent-columns=5 +--line-up-parentheses +--maximum-line-length=35 + ==> b131.in <== unless ( open( SCORE, "+>>$Score_File" ) ) diff --git a/lib/Perl/Tidy/Formatter.pm b/lib/Perl/Tidy/Formatter.pm index 28faa601..8514480e 100644 --- a/lib/Perl/Tidy/Formatter.pm +++ b/lib/Perl/Tidy/Formatter.pm @@ -19959,6 +19959,11 @@ EOM $space_count += $standard_increment; } + # do not start -lp under stress .. fixes b1244 + elsif ( !$in_lp_mode && $level > $stress_level + 1 ) { + $space_count += $standard_increment; + } + # otherwise use the space to the first non-blank level change else { -- 2.39.5