All,
I have been stumped by this one for a while, and was hoping you all could help. I have a pair of classes, the second inherits from the first -- like this:
package Foo::Bar;
use strict;
use Exporter;
use vars qw( @ISA @EXPORT_OK );
@ISA = qw(Exporter);
@EXPORT_OK = qw(&doSomething);
sub new {
blah blah blah...
}
sub dosomething {
blah blah blah
}
package Foo::Bar::Blah;
use strict;
use Foo::Bar qw(doSomething);
use vars qw( @ISA );
@ISA = qw(Foo::Bar);
Now in (sample) code I have the following:
use strict;
use Foo::Bar::Blah;
Foo::Bar::Blah::doSomething('xyz');
I get the following error:
Use of inherited AUTOLOAD for non-method Foo::Bar::Blah::doSomething()
+ is deprecated at ./tests/testFooBarBlah.pl ...
Can't locate auto/Foo/Bar/Blah/doSomething.al in @INC ...
This doSomething() function is intended to be able to be called as either a method of an instance or a straight function call.
If I call it like:
Foo::Bar::doSomething('xyz');
There is no issue reported, and it appears to function properly.
Can anybody shed some light on this?
Note: this is using perl 5.8.2