From 7876eaffd6f86cc0dd7a3909051f637d39361798 Mon Sep 17 00:00:00 2001 From: Kaz Kylheku Date: Fri, 4 Apr 2025 20:26:07 -0700 Subject: infix: assignment must be right associative * stdlib/infix.tl (toplevel): The := operator must be assoc :right so a := b := c becomes (set a (set b c)) and not (set (set a b) c). --- stdlib/infix.tl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/stdlib/infix.tl b/stdlib/infix.tl index 73b4caf4..e45560aa 100644 --- a/stdlib/infix.tl +++ b/stdlib/infix.tl @@ -48,7 +48,7 @@ trunc floor ceil round lognot))) (new (ifx-oper 0 fun) arity :prefix assoc :right funp t)) -(new (ifx-oper 10 ':=) lispsym 'set) +(new (ifx-oper 10 ':=) assoc :right lispsym 'set) (new (ifx-oper 11 'or)) (new (ifx-oper 12 'and)) (new (ifx-oper 13 'not) arity :prefix assoc :right) -- cgit v1.2.3