Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl Monk, Perl Meditation

Re: Need a test for deep equality

by andreychek (Parson)
on Apr 20, 2002 at 15:43 UTC ( #160790=note: print w/replies, xml ) Need Help??

in reply to Need a test for deep equality

There is a module for this over at CPAN called Struct::Compare. From the description:

Compares two values of any type and structure and returns true if they are the same. It does a deep comparison of the structures, so a hash of a hash of a whatever will be compared correctly.

So, you just pass in two structures, and it returns true or false, based on whether or not the structures are equal.

Hope that helps!

Log In?

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://160790]
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others contemplating the Monastery: (4)
As of 2022-01-25 12:27 GMT
Find Nodes?
    Voting Booth?
    In 2022, my preferred method to securely store passwords is:

    Results (66 votes). Check out past polls.