On page 30, section 10, we have the example:

  (let ()
    (define-syntax foo
      (lambda (e)
        (let ([+ -]) (+ 1 2))))
    (define + 2)
    (foo))

The second argument of |define-syntax| should
evaluate to a transformer (pg 31, 11.2.2).
A tranformer is...a procedure that must...
return a syntax object (lib pg 51, 12.3).

The procedure in the example returns a number.

It should be:

  (let ()
    (define-syntax foo
      (lambda (e)
        #'(let ([+ -]) (+ 1 2))))
    (define + 2)
    (foo))

A similar change should be made to the corresponding
example above, e.g.

  (let ()
    (define-syntax foo
      (lambda (e)
        #'(+ 1 2)))
    (define + 2)
    (foo))

so that it violates only the restriction that is
to be illustrated, and not others.

  -- Keith

_______________________________________________
r6rs-discuss mailing list
[email protected]
http://lists.r6rs.org/cgi-bin/mailman/listinfo/r6rs-discuss

Reply via email to