in reply to Re2: maintaining constructor inheritance cascade
in thread maintaining constructor inheritance cascade

Excellent, it is an improvement - so I end up with proper cascading constructors using:
sub new { my $class = shift; my $self = $class->SUPER::new(@_); $self->_initChild(@_); return $self; }

Which is cleaner than looking at @ISA for a possible parent.

Thanks!

Replies are listed 'Best First'.
Re4: maintaining constructor inheritance cascade
by chip (Curate) on May 14, 2003 at 16:08 UTC
    Well, actually, SUPER does look at @ISA ... more significantly, perhaps, it looks at the @ISA in the current package, which may have nothing at all to do with the actual class of the object that you may or may not be working with at a given time. But oddly enough that's usually the right thing. Weird.

        -- Chip Salzenberg, Free-Floating Agent of Chaos