]> git.donarmstrong.com Git - perltidy.git/commitdiff
remove some old double sigle code
authorSteve Hancock <perltidy@users.sourceforge.net>
Thu, 5 May 2022 01:20:07 +0000 (18:20 -0700)
committerSteve Hancock <perltidy@users.sourceforge.net>
Thu, 5 May 2022 01:20:07 +0000 (18:20 -0700)
lib/Perl/Tidy.pm

index 762b21239f59b64c387bb02514e808c255d93e68..15eeb7fd239852ffe9e1d69de65d716b2c9b2585 100644 (file)
@@ -3883,7 +3883,7 @@ New abbreviations may be defined in a .perltidyrc file.
 For a list of all long names, use perltidy --dump-long-names (-dln).
 --------------------------------------------------------------------------
 EOM
-    foreach my $abbrev ( sort keys %$rexpansion ) {
+    foreach my $abbrev ( sort keys %{$rexpansion} ) {
         my @list = @{ $rexpansion->{$abbrev} };
         print STDOUT "$abbrev --> @list\n";
     }
@@ -4245,15 +4245,15 @@ sub read_config_file {
             $opening_brace_line = $line_no unless ( $body && $body =~ s/\}$// );
 
             # handle a new alias definition
-            if ( ${$rexpansion}{$name} ) {
+            if ( $rexpansion->{$name} ) {
                 local $" = ')(';
-                my @names = sort keys %$rexpansion;
+                my @names = sort keys %{$rexpansion};
                 $death_message =
                     "Here is a list of all installed aliases\n(@names)\n"
                   . "Attempting to redefine alias ($name) in config file $config_file line $.\n";
                 last;
             }
-            ${$rexpansion}{$name} = [];
+            $rexpansion->{$name} = [];
         }
 
         # leading opening braces not allowed
@@ -4294,7 +4294,7 @@ EOM
 
                 # remove leading dashes if this is an alias
                 foreach ( @{$rbody_parts} ) { s/^\-+//; }
-                push @{ ${$rexpansion}{$name} }, @{$rbody_parts};
+                push @{ $rexpansion->{$name} }, @{$rbody_parts};
             }
             else {
                 push( @config_list, @{$rbody_parts} );