Hi!
Nice to see you.
I'm new to OOP Peal.
Let me ask you a silly question.
When I try to use 'use base', I encountered an problem.
I wrote this program;
--- Animal.pm
package Animal;
sub speak {
my $class = shift;
print "a $class goes "
Hi.
Please allow me to ask another silly question.
I wrote the program and it works fine.
Animal.pm
package Animal;
use Exporter;
@ISA = qw(Exporter);
@EXPORT = qw(speak);
sub speak {
print "I speak!\n";
}
1;
-
sts, should be found on
this system using "man perl" or "perldoc perl". If you have access to the
Internet, point your browser at http://www.perl.org/, the Perl Home Page.
wirh Windows XP SP2.
Thank you !
-- jackm
2007/7/18, Jack Minoshima <[EMAIL PROTECTED]>:
Hi!
N
Paul and Paul,
Thank you very much !
I heard that OO module usually doesn't export anything,
but I just wanted the difference between use and use base.
Now almost everything is clear for me !
Just one thing, this code seems to work.
--
Munia,
Thank you very much !
Now everything is clear for me.
I know no use strict 'subs' allows bare word,
but I didn't know Perl would automatically quotes bareword ;)
Thank you again.