Alias
view release on metacpan or search on metacpan
Given a list of name => value pairs, declares aliases
in the C<caller>s namespace. If the value supplied is a reference, the
alias is created for the underlying value instead of the reference
itself (there is no need to use this module to alias references--they
are automatically "aliased" on assignment). This allows the user to
alias most of the basic types.
If the value supplied is a scalar compile-time constant, the aliases
become read-only. Any attempt to write to them will fail with a run time
error.
Aliases can be dynamically scoped by pre-declaring the target variable as
C<local>. Using C<attr> for this purpose is more convenient, and
recommended.
=item attr
Given a hash reference, aliases the values of the hash to the names that
correspond to the keys. It always returns the supplied value. The aliases
are local to the enclosing block. If any of the values are unblessed
( run in 0.561 second using v1.01-cache-2.11-cpan-65fba6d93b7 )