[r6rs-discuss] Names in let* bindings
Section 5.7 of R5.91RS says implementations must detect syntax
violations. In the definition of (let), section 9.5.6 says, "It is a
syntax violation for a <variable> to appear more than once in the list
of variables being bound." Section 9.5.6 then defines (let*) as
similar to let, but the bindings
are performed sequentially from left to right, and the
region of a binding indicated by (<variable> <init>) is that
part of the let* expression to the right of the binding.
I can't tell if the restriction on variable names in (let) is meant to
apply to (let*). Is the following allowed?
(let* ((foo (make-foo))
(foo (decorate foo)))
...)
If so, the spec could be clearer. If not, the example implementation
of (let*) using syntax-rules would appear to be incorrect. It doesn't
detect the error.
-j
Received on Wed Oct 25 2006 - 06:53:04 UTC
This archive was generated by hypermail 2.3.0
: Wed Oct 23 2024 - 09:15:01 UTC