summaryrefslogtreecommitdiff
path: root/configpm
diff options
context:
space:
mode:
authorNicholas Clark <nick@ccl4.org>2011-02-19 17:33:43 +0000
committerNicholas Clark <nick@ccl4.org>2011-02-19 17:33:43 +0000
commite736dcee3f1af41c202d6752407391cb1e0a4664 (patch)
treed78e897b6a25ea9c125764fb44b7fb6fa5bcb152 /configpm
parent9fe67fcb38b1ebebba702342586dd43ab996153b (diff)
downloadperl-e736dcee3f1af41c202d6752407391cb1e0a4664.tar.gz
In Config, use typeglob aliasing instead of subref to typeglob assignment.
Typeglob aliasing saves just over .5K, because fewer internal structures are created. In the general case the behaviour of the two differs, but as the only package variables of these names are subroutines, and we are within our own namespace, there is no difference here.
Diffstat (limited to 'configpm')
-rwxr-xr-xconfigpm4
1 files changed, 1 insertions, 3 deletions
diff --git a/configpm b/configpm
index 2de7676394..55404a52d9 100755
--- a/configpm
+++ b/configpm
@@ -707,9 +707,7 @@ $heavy_txt .= <<'ENDOFEND';
}
sub STORE { die "\%Config::Config is read-only\n" }
-*DELETE = \&STORE;
-*CLEAR = \&STORE;
-
+*DELETE = *CLEAR = \*STORE; # Typeglob aliasing uses less space
sub config_sh {
substr $Config_SH_expanded, 1, $config_sh_len;