Class::Method::Cannot?

David Cantrell david at cantrell.org.uk
Mon Apr 28 22:16:51 BST 2008


On Mon, Apr 28, 2008 at 03:52:41PM -0500, Ian Malpass wrote:
> Abigail wrote:
> >On Mon, Apr 28, 2008 at 06:04:44PM +0100, heno-fijw at xemaps.com wrote:
> >>The way I'd do this is to import all the other subs apart from foo and
> >>bar into your namespace. You could do this on demand with some AUTOLOAD
> >>magic, which will continue to get called each time foo() and bar() are
> >>called.
> >I think that would fail to work correctly if any of the imported methods
> >uses SUPER; IIRC, I've written code that (ab)uses this.
> Plus, you'd have to know which subs to import, rather than which ones to 
> avoid.

The list of subs to import is the list of all subs minus the ones to
avoid.  And getting the list of all subs is easy - modulo AUTOLOADing of
course.

-- 
David Cantrell | Enforcer, South London Linguistic Massive

    Safety tip: never strap firearms to a hamster


More information about the london.pm mailing list