New module on its way to CPAN

Stray Toaster mwk at stray-toaster.co.uk
Wed Nov 27 11:08:29 CST 2002


On Wed, Nov 27, 2002 at 04:59:27PM +0000, Jasper McCrea wrote:
> In fact, you have to type more characters to use this than just to write:
> 
> my $hashref = { map %$_, $ref1, $ref2, ... };
> 
> cf
> 
> use HashRef.pm;
> my $hashref = merge_hashref($ref1, $ref2, ...);
> 
> Isn't this false laziness?

probably. As opposed to me remembering to do the map bit, with the
braces and all, I erase that from my mind and just remember
merge_hashref.

For the same reason as File::Slurp. Everyone knows how to open a file
and read it in, as it only takes a few lines, but it is so much easier
to do

use File::Slurp;

my $foo = read_file($filename);

Oh, leave me alone! Just cause you are taller than me...

m.

-- 
No, I am not laughing with you

--
Family ties : http://www.thefamilykerr.co.uk
Playtime    : http://www.stray-toaster.co.uk



More information about the Belfast-pm mailing list