I'm implementing syntax-parameterize in my Scheme interpreter and testing the implementation with Chez Scheme and found a bug in Chez. Here is a use case:
(define-syntax foo
(syntax-rules ()
((_ body ...)
(begin
(syntax-parameterize
((it (syntax-rules ()
((_) "hello world")))))
body ...))))
Sorry my bad, I was confused about error messages because it didn't give an error about unbound syntax-parameterize only about (it) because it tried to execute it from this expression:
I'm implementing syntax-parameterize in my Scheme interpreter and testing the implementation with Chez Scheme and found a bug in Chez. Here is a use case:
Where the body is outside of
syntax-parameterize
.Both expressions:
throws:
But it should throw an error about 10 not being a function. This should work:
and display
10
but it gives an exception.The above works in Guile.