[plt-scheme] syntax-local-context?

From: jos koot (jos.koot at telefonica.net)
Date: Wed Feb 14 08:53:35 EST 2007

The following confuses me:

(define-syntax (show-local-context stx)
 (syntax-case stx ()
  ((show-local-context x)
   (let ((x (syntax x)))
    (printf "~s ~s.~n" (syntax-object->datum x) (syntax-local-context))

(let ((d (show-local-context (add1 2)))) d) ; --> 3
; displayed: (add1 2) top-level.

I expected display: (add1 2) expression. Do I misunderstand the manual or 
(less probably) is this a bug?

(((((lambda(x)((((((((x x)x)x)x)x)x)x)x))
    (lambda(x)(lambda(y)(x(x y)))))
  (lambda()(printf "Greetings, Jos~n")))) 

Posted on the users mailing list.