Re: Slurpy nullary vs nonslurpy nullary

2005-02-22 Thread Autrijus Tang
On Tue, Feb 22, 2005 at 10:38:04PM +1100, Damian Conway wrote: > >So, even if the clash is Num vs Str context, we still run it > >under List context? Or is it their common ancestor, "Scalar"? > > Yes. When I said "indeterminate contexts" I meant List vs Scalar. After > all, the whole point of mu

Re: Slurpy nullary vs nonslurpy nullary

2005-02-22 Thread Damian Conway
Autrijus wrote: Personally, I think the only reasonable way of resolving this is to assume (as in the last paragraph above) that function calls in these kinds of indeterminate contexts are always in list context. So, even if the clash is Num vs Str context, we still run it under List context? Or i

Re: Slurpy nullary vs nonslurpy nullary

2005-02-21 Thread Autrijus Tang
On Tue, Feb 22, 2005 at 09:41:54AM +1100, Damian Conway wrote: > Personally, I think the only reasonable way of resolving this is to > assume (as in the last paragraph above) that function calls in these > kinds of indeterminate contexts are always in list context. So, even if the clash is Num vs

Re: Slurpy nullary vs nonslurpy nullary

2005-02-21 Thread Damian Conway
Autrijus wrote: > A difficulty arises because the expressions used as arguments > is not evaluated when arityMatch is done, and for good reason -- > they may do wildly different things depending on its context. > > When Pugs was only implementing FP6, I could affort to force > evaluation for each m

Re: Slurpy nullary vs nonslurpy nullary

2005-02-21 Thread Larry Wall
On Sat, Feb 19, 2005 at 12:44:49AM +0800, Autrijus Tang wrote: : On Fri, Feb 18, 2005 at 08:26:26AM -0800, Larry Wall wrote: : > So I think your initial solution is actually the right one from the : > viewpoint of the Perl programmer. If we need to tweak something, : > it's perhaps to document the

Re: Slurpy nullary vs nonslurpy nullary

2005-02-18 Thread Autrijus Tang
On Fri, Feb 18, 2005 at 08:26:26AM -0800, Larry Wall wrote: > Just as a BTW, that syntax is illegal currently, since those > curlies would be interpreted as hash subscripts. Noted. Which reminds me I need to implement hashes... :) > : It sort of makes sense to me. Please correct me if it's wron

Re: Slurpy nullary vs nonslurpy nullary

2005-02-18 Thread Larry Wall
On Fri, Feb 18, 2005 at 04:25:49PM +0800, Autrijus Tang wrote: : After getting Life and Mandel to run on Pugs yesterday (see : http://svn.perl.org/perl6/pugs/trunk/examples/ ), today I've : made this version of Quicksort to run: : : use v6; : : multi sub quicksort ( ) { () } : : mult

Slurpy nullary vs nonslurpy nullary

2005-02-18 Thread Autrijus Tang
After getting Life and Mandel to run on Pugs yesterday (see http://svn.perl.org/perl6/pugs/trunk/examples/ ), today I've made this version of Quicksort to run: use v6; multi sub quicksort ( ) { () } multi sub quicksort ( *$x, [EMAIL PROTECTED] ) { my @pre = @xs.grep{ $_ < $x