On Tue, Apr 06, 2004 at 05:15:17PM -0500, Andrew Gaffney wrote:

> How do you determine what type of data a reference points to? I have a 
> function (one in previous post) that can take either an array of scalars or 
> an array of hash references. I want to execute different code based on 
> which one it was. How can I do that?

Take a look at ref and UNIVERSAL::isa.

perldoc -f ref
perldoc UNIVERSAL

-- 
Paul Johnson - [EMAIL PROTECTED]
http://www.pjcj.net

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>


Reply via email to