Subject: | eval { use ... } does not do what you want |
As per subject. I found the broek idiom with
http://search.cpan.org/grep?release=Set-IntSpan-Partition-0.03;string=Test::Pod|Test::Pod::Coverage;n=1;C=0
The reason why this idiom makes no sense is the three way parse nature of perl that executes use statements as they come before paying attention to the eval {}. That way a missing library leads to a fail before the statement finishes its compilation.
Sample fail reports:
http://www.cpantesters.org/cpan/report/90036575
http://www.cpantesters.org/cpan/report/90036653
Gruesse!