avarus has asked for the wisdom of the Perl Monks concerning the following question:


OK, this should be dead easy but every permutation I try throws an error.
Slightly cleaned up version is that I have a class 'bar' which ISA 'foo' and I call the method 'dostuff', but under certain conditions I want to delegate to the superclass:

#in package bar sub dostuff { return $_[0]->SUPER::dostuff() if $condition; }
That works, but I really want to say:
sub dostuff { goto &{ $_[0]->SUPER::dostuff } if $condition; }
IE - clean up the stack and continue as if the method in the subclass never existed.
But I cannot summon the correct syntax. Any ideas?



-- #Tip: use 'no strict' to make those nasty errors vanish.