| Prev | Code Coverage - Tales From the Trenches | 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 8 | YAPC::Europe::2003 | Copyright © 2003 Paul Johnson |