On Sun Oct 30 17:51:24 2016, tonyc wrote: > On Wed Oct 26 02:07:15 2016, haukex@zero-g.net wrote: > > Dear P5Porters, > > > > I noticed that @ISA isn't documented in perlvar, so I copied & pasted > > some > > wordings from other places to make an entry for perlvar.pod, all > > credit > > goes to those other PODs I stole from ;-) It's just meant to be a > > starting > > point, so I'd be happy to hear any suggestions or changes to the > > patch. > > > > Thanks, Regards, > > -- Hauke D > > +It is possible to manually set C<@ISA>, but it is recommended to use > +L<parent> to declare parent classes. > > Is it recommended? By some and not by others. > > This pragma will take care of setting > +C<@ISA> and will also load the parent classes and make sure that the > +package doesn't inherit from itself. > > Setting @ISA directly also checks for recursive inheritence: > > $ ./perl -e 'package Foo; our @ISA = "Bar"; package Bar; our @ISA = > "Foo";' > Recursive inheritance detected in package 'Bar' at -e line 1. I think it would be better for perlvar to begin by explaining what the variable does and what it is for, and *then* also mention that parent.pm *can* be used to set it. -- Father Chrysostomos --- via perlbug: queue: perl5 status: open https://rt.perl.org/Ticket/Display.html?id=129967Thread Next