(...) on the Internet (the whole Internet!)
Then CPAN is not on the Internet?
UNIVERSAL::require does all you want.require UNIVERSAL::require; my $module_name = 'Regexp::Common'; $module_name->use(qw /comment number/); my $test = '123.456'; print $test =~ $RE{num}{real} ? 'A number' : 'Something else';
CountZero
A program should be light and agile, its subroutines connected like a string of pearls. The spirit and intent of the program should be retained throughout. There should be neither too little or too much, neither needless loops nor useless variables, neither lack of structure nor overwhelming rigidity." - The Tao of Programming, 4.1 - Geoffrey James
In reply to Re: import() when require-d module name is variable
by CountZero
in thread import() when require-d module name is variable
by akujbida
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |