Ovid schrieb am 25.11.2011 um 23:58 (-0800):
> Rename TB2::Mouse to something like TB2::_U_R_A_MORON_FOR_USING_THIS_
> and I think the problem will take care of itself.
Or what about an addition to TB2::Mouse's import routine?
sub import {
# prevent unauthorised use
my $calling_pkg = (caller)[0];
croak __PACKAGE__ . ' is for internal use only'
unless $calling_pkg =~ m/^(:?Test|TB2)::/;
# or some other suitable usage policy check
...
Wouldn't that practically solve the hypothetical problem?
--
Michael Ludwig