http://qs1969.pair.com?node_id=781934


in reply to Test Presence of Data in Hash

If you need to compare a hash against a (empty) hash ;)

#!/usr/bin/perl use strict; use warnings; use Data::Compare; my %h1 = ( 1 => 'boo', 2 => 'bar', 3 => 'baz' ); my $c = new Data::Compare( \%h1, {} ); print '%h1 is ', $c->Cmp ? '' : 'not ', "empty.\n";


hth,
PooLpi

'Ebry haffa hoe hab im tik a bush'. Jamaican proverb