From 57cbd9fe4fc8ff17a806151ae996cd39268e7587 Mon Sep 17 00:00:00 2001 From: Kaz Kylheku Date: Fri, 4 Apr 2025 19:58:08 -0700 Subject: infix: adjust operator expected diagnostic. * stdlib/infix.tl (parse-infix): The operator expected diagnostic can occur not just before an an operand, but before an prefix operator. For instance "a cos b". An operator is expected between a and cos. We don't want to say "before operand cos" because cos is an operator. --- stdlib/infix.tl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/stdlib/infix.tl b/stdlib/infix.tl index 31712a10..73b4caf4 100644 --- a/stdlib/infix.tl +++ b/stdlib/infix.tl @@ -140,7 +140,7 @@ ((@tok . @rest) (if (or (not ucheck) (eq (first opstack).?arity :postfix)) - (infix-error oexp "operator expected before operand ~s" tok)) + (infix-error oexp "operator expected before ~s" tok)) (push tok nodestack) (set ucheck nil exp rest))) -- cgit v1.2.3