Re: When do named subs bind to their variables? (Re: Questionable scope of state variables ([perl #113930] Lexical subs))

2012-07-09 Thread Father Chrysostomos via RT
On Sat Jul 07 18:35:03 2012, tom christiansen wrote: Father Chrysostomos via RT perlbug-comm...@perl.org wrote on Sat, 07 Jul 2012 17:44:46 PDT: I’m forwarding this to the Perl 6 language list, so see if I can find an answer there. I do have an answer from Damian, which I will

When do named subs bind to their variables? (Re: Questionable scope of state variables ([perl #113930] Lexical subs))

2012-07-09 Thread Father Chrysostomos via RT
I’m forwarding this to the Perl 6 language list, so see if I can find an answer there. [This conversation is about how lexical subs should be implemented in Perl 5. What Perl 6 does may help in determining how to iron out the edge cases.] On Sat Jul 07 13:23:17 2012, sprout wrote: On Sat Jul

Re: When do named subs bind to their variables? (Re: Questionable scope of state variables ([perl #113930] Lexical subs))

2012-07-07 Thread Tom Christiansen
Father Chrysostomos via RT perlbug-comm...@perl.org wrote on Sat, 07 Jul 2012 17:44:46 PDT: I’m forwarding this to the Perl 6 language list, so see if I can find an answer there. I do have an answer from Damian, which I will enclose below, and a Rakudo result for you. [This conversation

Re: When do named subs bind to their variables? (Re: Questionable scope of state variables ([perl #113930] Lexical subs))

2012-07-07 Thread Tom Christiansen
Father Chrysostomos via RT perlbug-comm...@perl.org wrote on Sat, 07 Jul 2012 18:54:15 PDT: Thank you. So the bar sub seems to be closing over the name @a (the container/variable slot/pad entry/whatever), rather than the actual array itself. Since I don't have it installed, could you tell

Re: When do named subs bind to their variables? (Re: Questionable scope of state variables ([perl #113930] Lexical subs))

2012-07-07 Thread Damian Conway
Father Chrysostomos asked: What I am really trying to find out is when the subroutine is actually cloned, Yes. It is supposed to be (or at least must *appear* to be), and currently is (or appears to be) in Rakudo. and whether there can be multiple clones within a single call of the