in reply to •Re: Avoiding the Use of @ISA = qw(Foo::Bar);
in thread Avoiding the Use of @ISA = qw(Foo::Bar);

I want an extra layer of indirection between me and @ISA, because I don't like assuming that @ISA was already empty when I said our @ISA = qw(Foo);. use base provides that layer and gives you a little extra stuff.

----
I wanted to explore how Perl's closures can be manipulated, and ended up creating an object system by accident.
-- Schemer

Note: All code is untested, unless otherwise stated

Replies are listed 'Best First'.
•Re: Re: •Re: Avoiding the Use of @ISA = qw(Foo::Bar);
by merlyn (Sage) on Jul 14, 2003 at 18:08 UTC
    Yes, but who else would set it, other than your definition of your module? You need to have one place in your program with a clear declaration of the inheritance of that class.

    -- Randal L. Schwartz, Perl hacker
    Be sure to read my standard disclaimer if this is a reply.