Class::ISA might be useful in this case -- you can just ask each class if it supports 'validate()' and if so print that out, like this untested:
sub validate { my $self = shift; # do validation foreach my $parent_class ( Class::ISA::super_path( ref $self ) ) { if ( $parent_class->can( 'validate' ) ) { print "Will call '$parent_class->validate()'\n"; last; } } return $self->SUPER::validate(@_); }
Chris
M-x auto-bs-mode
In reply to Re: tracing SUPER
by lachoy
in thread tracing SUPER
by Ranger Rick
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |