Re: 'temp $x;' with no assignment

2006-04-07 Thread Larry Wall
On Thu, Apr 06, 2006 at 05:36:56PM -0600, Luke Palmer wrote: : On 3/27/06, Larry Wall [EMAIL PROTECTED] wrote: : The p5-to-p6 translator will turn : : local $x; : : into : : temp undefine $x; : : Are you sure that that's not: : : undefine temp $x; : : It seems to me that the

Re: 'temp $x;' with no assignment

2006-04-06 Thread Eric
On 3/27/06, Larry Wall [EMAIL PROTECTED] wrote: On Mon, Mar 27, 2006 at 02:54:05PM -0600, Jonathan Scott Duff wrote: : On Mon, Mar 27, 2006 at 10:46:02PM +0200, Yuval Kogman wrote: : On Mon, Mar 27, 2006 at 14:35:52 -0600, Jonathan Scott Duff wrote: : I think that if Ctemp is the new

Re: 'temp $x;' with no assignment

2006-04-06 Thread Luke Palmer
On 3/27/06, Larry Wall [EMAIL PROTECTED] wrote: The p5-to-p6 translator will turn local $x; into temp undefine $x; Are you sure that that's not: undefine temp $x; It seems to me that the other way would undefine $x and then temporize it. Luke

'temp $x;' with no assignment

2006-03-27 Thread Yuval Kogman
Hi, my $x = 5; { temp $x; # is $x 5 or undef? } # $x is definately 10 I think it should be 5 inside, because it makes it easy to write things like: my $x = 5; { temp $x++; # $x is 6

Re: 'temp $x;' with no assignment

2006-03-27 Thread Jonathan Scott Duff
On Mon, Mar 27, 2006 at 05:26:48PM +0200, Yuval Kogman wrote: Hi, my $x = 5; { temp $x; # is $x 5 or undef? } # $x is definately 10 How did $x become 10?!?!? :-) I think it should be 5 inside, because it makes it easy to write

Re: 'temp $x;' with no assignment

2006-03-27 Thread Yuval Kogman
On Mon, Mar 27, 2006 at 14:35:52 -0600, Jonathan Scott Duff wrote: On Mon, Mar 27, 2006 at 05:26:48PM +0200, Yuval Kogman wrote: How did $x become 10?!?!? :-) GHC has this lovely error: my brain just exploded I think Perl 6 should have a similar runtime warning about how it's usiong my short

Re: 'temp $x;' with no assignment

2006-03-27 Thread Jonathan Scott Duff
On Mon, Mar 27, 2006 at 10:46:02PM +0200, Yuval Kogman wrote: On Mon, Mar 27, 2006 at 14:35:52 -0600, Jonathan Scott Duff wrote: I think that if Ctemp is the new Clocal, then immediately after the Ctemp $x line, $x should hold whatever flavor of undef is appropriate. snip Is there some

Re: 'temp $x;' with no assignment

2006-03-27 Thread Yuval Kogman
On Mon, Mar 27, 2006 at 14:54:05 -0600, Jonathan Scott Duff wrote: Make me believe your 90/10 numbers. http://cpansearch.bulknews.net/ is broken right now... =( -- Yuval Kogman [EMAIL PROTECTED] http://nothingmuch.woobling.org 0xEBD27418 pgpCMeQfldQFY.pgp Description: PGP signature

Re: 'temp $x;' with no assignment

2006-03-27 Thread Larry Wall
On Mon, Mar 27, 2006 at 02:54:05PM -0600, Jonathan Scott Duff wrote: : On Mon, Mar 27, 2006 at 10:46:02PM +0200, Yuval Kogman wrote: : On Mon, Mar 27, 2006 at 14:35:52 -0600, Jonathan Scott Duff wrote: : I think that if Ctemp is the new Clocal, then immediately after the : Ctemp $x line, $x