On Thu, Jun 4, 2020 at 8:16 PM Marc Nieper-Wißkirchen <xxxxxx@nieper-wisskirchen.de> wrote:
A variable reference *is* syntax, so this doesn't preclude `yield'
bound to a variable instead of a transformer.

Ah, yes.  But if you say "yield is an identifier bound to syntax." as in the current srfi text, it does sound something special.
 
(define-coroutine-generator f
  (yield (lambda () (yield 1))))

(define-coroutine-generator g
  (yield
   (let ((x (f)))
     (if (proc? x) (x) x)))))

(g) ;=> 1

This won't work with dynamic scoping of `yield'. (One can probably
think of a much simpler example.)

This yields 1 in my implementation (with replacing proc? with procedure?). 
Is it supposed to work differently?