문제

I understand that syntax-rules is a hygienic macro system, but I do not understand why this happens:

(define not (lambda (x) x))

(define-syntax nand
  (syntax-rules ()
    ((_ a b)
     (not (and a b)))))

(nand #f #t)

==> #f

Now, if I had redefined not after defining the macro, then (nand #f #t) returns #t. Why, if the macro system is supposed to be hygienic?

올바른 솔루션이 없습니다

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top