if(exists $hash_ref{$block} and !defined $hash_ref{$block}{$libName}) { print "This is a test\n"; }