Re: RFC 82 (v3) Arrays: Apply operators element-wise in a list context
[email protected] (Chaim Frenkel) 09 Sep 2000 22:33:32 -0400
| Newsgroups | perl.perl6.language.data |
|---|---|
| Message-ID | <[email protected]> |
>>>>> "NT" == Nathan Torkington <[email protected]> writes: NT> Actually, the only refinement I'd like to see is that boolean operators NT> (==, &&, ||) be excepted from the distributive rule. NT> This is to permit: NT> if (@a == @b) # shallow comparison NT> and NT> @a = @b || @c; # @a=@b or @a=@c; # ish NT> The math operations are fine to apply to each element. I have no NT> problem with those being distributive, but I think || for default NT> values and == for comparison are too ingrained and they'd be too NT> useful (as opposed to a distributive || or &&, which is much less NT> useful). Then how would one get the distributed effect? An apply operator? <chaim> -- Chaim Frenkel Nonlinear Knowledge, Inc. [email protected] +1-718-236-0183