Pap Taylor pap at
Thu Nov 30 06:04:24 CST 2000

>In which case you see some benefit in using references, as you're not
>merging the entire passed structure to @_. Anything larger than a scalar
>benefits from this lack of merging... Even small arrays.

It's worth pointing out that if you're using named parameters, you'll have 
to pass arrays as refs in order to access them the way you want.

Otherwise, your key ( at best ) will refer to the first element of your 
array - or worse - won't be a key at all anymore.

If you're serious about accessing big old data structures, you're better 
off realising your module as a class, and simply storing the data structure 
as an attribute of that object.  Then, it's accessible through all of your 
subs as $self->{whatever}.


More information about the Southampton-pm mailing list