# perl -e 'use My::Module::Account qw(_GenerateAccountSummary); _Gener
+ateAccountSummary();'
Undefined subroutine &main::_GenerateAccountSummary called at -e line
+1.
Three possibilities:
-
&My::Module::Account::import doesn't exist and My::Module::Account doesn't inherit a method named import.
Test:
perl -wle'use My::Module::Account qw(_GenerateAccountSummary); print M
+y::Module::Account->can("import") || "no"'
-
The import does not create a sub named _GenerateAccountSummary in the caller's namespace in response to the call.
Test:
perl -wle'use My::Module::Account qw(_GenerateAccountSummary); print *
+{$::{_GenerateAccountSummary}}{CODE} || "no"'
-
_GenerateAccountSummary is successfully exported, but it has not been defined.
Test:
perl -wle'use My::Module::Account qw(_GenerateAccountSummary); print d
+efined(&_GenerateAccountSummary) ? "yes" : "no"'
The first to output "no" indicates the cause.