develooper Front page | perl.perl6.language | Postings from June 2005

Re: reduce metaoperator on an empty list

Thread Previous | Thread Next
From:
Sam Vilain
Date:
June 6, 2005 17:30
Subject:
Re: reduce metaoperator on an empty list
Message ID:
42A4EA82.4070009@vilain.net
Roger Hale wrote:
> This is why I would rather the o -> [o] circumfixion left [o] an infix, 
> not prefix operator.  I would rather be explicit about my identity:
>     $product = 1 [*] @array;

Hmm.  Not all operators *have* an identity.

You'd have to write, in that case;

       @array[0] [ƒ] @array[1..@array.end]

Which isn't great IMHO.

Sam.

Thread Previous | Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About