]> git.donarmstrong.com Git - perltidy.git/commitdiff
minor fix - include hanging side comments in alignment tree construction
authorSteve Hancock <perltidy@users.sourceforge.net>
Wed, 1 Jul 2020 12:35:14 +0000 (05:35 -0700)
committerSteve Hancock <perltidy@users.sourceforge.net>
Wed, 1 Jul 2020 12:35:14 +0000 (05:35 -0700)
lib/Perl/Tidy/VerticalAligner.pm

index c1222c47e99c1541953fa5ed662e8a487cec775e..388a2b3482999c9709eea2a8a86f8f4225e94e1c 100644 (file)
@@ -3246,6 +3246,11 @@ sub prune_alignment_tree {
             $end_node->( 0, $jm, $n_parent );
         }
 
+        # Continue at hanging side comment
+        elsif ( $rlines->[$jp]->{_is_hanging_side_comment} ) {
+             next;
+        }
+
         # Otherwise see if anything changed and update the tree if so
         else {
             foreach my $depth ( 0 .. $MAX_DEPTH ) {