in reply to Re: OO sub, hash or hash reference.
in thread OO sub, hash or hash reference.

Out of curiosity, why the isa instead of a ref($_[0]) eq 'HASH'?

-pete
Entropy is not what is used to be.

Replies are listed 'Best First'.
Re: Re: Re: OO sub, hash or hash reference.
by IOrdy (Friar) on Feb 18, 2002 at 15:19 UTC
    after seeing the above code I did some reading:

    "The reason the original test is fragile ( ref($_[0]) eq 'HASH' ) is that it will make your code refuse to work on a hash if it happens to be blessed."

    It was simpler than I thought.