| Prev | Testing and Code Coverage | Next |
Protects against errors in which some requirements are not met in one branch
if ($x)
{
$h = { a => 1 }
}
else
{
$h = 0;
}
print $h->{a};
This code will fail if $x is false (and you are using strict refs).
| Slide 18 | YAPC::Europe::2002 | Copyright © 2002 Paul Johnson |