Operator precedence fiddling

2011-12-23 Thread Kris Shannon
sub infix:foo ($a, $b = ($a foo 2 * 3 - $a)) is tighter(infix:*) { $a == 0 ?? 1 foo 2 * 3 !! $a + $b } say 1 foo (2 * 3); # 7 say (1 foo 2) * 3; # 9 say 1 foo 2 * 3; # 9 say infix:foo(1); # Niecza: 7 say 0 foo 0; # Niecza: 9 The way that Niecza does this is to install the operator

Re: Operator precedence fiddling

2011-12-23 Thread Stefan O'Rear
On Fri, Dec 23, 2011 at 10:59:58PM +1100, Kris Shannon wrote: sub infix:foo ($a, $b = ($a foo 2 * 3 - $a)) is tighter(infix:*) { $a == 0 ?? 1 foo 2 * 3 !! $a + $b } say 1 foo (2 * 3); # 7 say (1 foo 2) * 3; # 9 say 1 foo 2 * 3; # 9 say infix:foo(1); # Niecza: 7 say 0 foo

[perl6/specs] e52fc1: Fix typo. $*ARGFILES is plural in all but one inst...

2011-12-23 Thread noreply
Branch: refs/heads/master Home: https://github.com/perl6/specs Commit: e52fc11b61767329480e0aee8df62060c020494c https://github.com/perl6/specs/commit/e52fc11b61767329480e0aee8df62060c020494c Author: Bruce Gray bruce.g...@acm.org Date: 2011-12-23 (Fri, 23 Dec 2011) Changed