in reply to Can Perl add single quotes?

You want check a variables by its name ? thus try something like this :
sub reality_test { my ( $var_name , $min , $max ) = @_; eval "print q($var_name is out of range !) if $var_name < $min or +$var_name > $max" } reality_test( '$foo' , 10 , 30 );
But is not really "programmatically correct" =)
__________________
Hope this helps