You are simply returning a string from the eval. Ommit the block curlies:
eval {""} to
eval ""
In terms of maintainability and ease (and saving the optimiser some work), I think that you should nest an eval in an eval if possible, to minimise the
interpolating run-time compilation, and get around mistakes. Also, where not needed you can add single quotes, and concatenate them with the variables (outside quoes) like this:
eval 'use Util::Test_util' # goes on
. $var_that_needs_interpolation
. 'do_stuff($var)'; # var is not interpolated
Update: I forgot to say that by nesting i mean use an
eval EXPR within an
eval BLOCK.
-nuffin
zz zZ Z Z #!perl