From 710378129ff9f892f76b0b94fdd960d9a60fba2e Mon Sep 17 00:00:00 2001
From: Steve Hancock <perltidy@users.sourceforge.net>
Date: Tue, 8 Sep 2020 11:21:42 -0700
Subject: [PATCH] do not allow -wc and -lp together, can cause bugs

---
 lib/Perl/Tidy/Formatter.pm | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/lib/Perl/Tidy/Formatter.pm b/lib/Perl/Tidy/Formatter.pm
index 512a7425..3c8bd757 100644
--- a/lib/Perl/Tidy/Formatter.pm
+++ b/lib/Perl/Tidy/Formatter.pm
@@ -6002,6 +6002,13 @@ with these flags.
 EOM
             $rOpts->{'line-up-parentheses'} = 0;
         }
+
+        if ( $rOpts->{'whitespace-cycle'} ) {
+            Warn(<<EOM);
+Conflict: -wc cannot currently be used with the -lp option; ignoring -wc
+EOM
+            $rOpts->{'whitespace-cycle'} = 0;
+        }
     }
 
     # At present, tabs are not compatible with the line-up-parentheses style
-- 
2.39.5