I don't think closure is something that is something to avoid. When used wisely (and perhaps with a bit of experience) it can be rather useful. I have not used it myself, but I see the potential for it.
Thanks for the enlightenment Perrin. ----- Original Message ----- From: "John ORourke" <[EMAIL PROTECTED]> To: "Perrin Harkins" <[EMAIL PROTECTED]> Cc: "angel flower" <[EMAIL PROTECTED]>; <modperl@perl.apache.org> Sent: Tuesday, October 18, 2005 11:33 PM Subject: Re: [OT] Re: a new mod_perl problem > Perrin Harkins wrote: > > > > >Good guess, but that's not what is happening here. What our flowery > >friend has stumbled onto is a closure. When a subroutine references a > >"my" variable that was declared outside of that subroutine's scope, the > >sub will keep a private copy of that variable. If it wasn't a closure, > > > > > > Ah, missed that bit in Perl 101... sounds like something to avoid > anyway, thanks! > > John