Hello,

I am unable to understand how free-identifier=? and bound-identifier=? works?

For example suppose I have a code :
   (lambda (x y) (let ([x 2]) x))

then how do I determine if last x in the body of let is not bound by first
parameter to lambda? , using either free-identifier=? or bound-identifier=? .

When I use them ,they both produces #t .

(define-syntax check
  (lambda (stx)
    (syntax-case stx (lambda let)
      [(_ (lambda (x y ...) (let ([a b]) c)))
       #'(values (free-identifier=? #'x #'c)
                 (bound-identifier=? #'x #'c))])))


(check (lambda (x y) (let ([x 2]) x)))
_________________________________________________
  For list-related administrative tasks:
  http://lists.racket-lang.org/listinfo/users

Reply via email to