in reply to bless!!
This calls, CLASS_A::new, which inherits to CLASS_B::new, which blesses the hashref into CLASS_A, not CLASS_B. Does that help?package CLASS_B; sub new { my $class = shift; # critical here bless { @_ }, $class; # blesses to maybe CLASS_A } package CLASS_A; @ISA = qw(CLASS_B); ... my $object = CLASS_A->new;
-- Randal L. Schwartz, Perl hacker
Be sure to read my standard disclaimer if this is a reply.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: •Re: bless!!
by bakunin (Scribe) on Jan 17, 2004 at 23:14 UTC |