]> git.donarmstrong.com Git - perltidy.git/commitdiff
call dump_block_summary after respace_tokens
authorSteve Hancock <perltidy@users.sourceforge.net>
Tue, 9 Apr 2024 14:09:19 +0000 (07:09 -0700)
committerSteve Hancock <perltidy@users.sourceforge.net>
Tue, 9 Apr 2024 14:09:19 +0000 (07:09 -0700)
sub respace tokens makes some essential data structures needed
for future updates to dump_block_summary.

lib/Perl/Tidy/Formatter.pm

index 7be5f95f51be750cf1f8ebb7870100a905045d58..1000728d9654a2a7c47c68fc824654a280099bf2 100644 (file)
@@ -6556,13 +6556,6 @@ Something may be wrong; formatting will be skipped.
 EOM
     }
 
-    # Dump any requested block summary data
-    if ( $rOpts->{'dump-block-summary'} ) {
-        if ($severe_error) { Exit(1) }
-        $self->dump_block_summary();
-        Exit(0);
-    }
-
     #----------------------------------------------------------------
     # Output file verbatim if severe error or no formatting requested
     #----------------------------------------------------------------
@@ -6611,6 +6604,12 @@ EOM
         $self->find_multiline_qw($rqw_lines);
     }
 
+    # Dump any requested block summary data
+    if ( $rOpts->{'dump-block-summary'} ) {
+        $self->dump_block_summary();
+        Exit(0);
+    }
+
     # Dump variable usage info if requested
     if ( $rOpts->{'dump-unusual-variables'} ) {
         $self->dump_unusual_variables();