[plt-scheme] Re: Novice question: evaluating symbols

From: Matthias Felleisen (matthias at ccs.neu.edu)
Date: Sat Jan 9 09:18:26 EST 2010

On Jan 9, 2010, at 4:17 AM, Laurent wrote:

> (Btw, isn't this macro hygienic?)


Of course not. You're introducing a synthetic name that binds stuff. 



> My main problem is that `syntax-rules', `syntax-case', `with-syntax' and others that I have not used yet use the syntax in quite different ways, and sometimes you have to #' and sometimes you have to (syntax->datum ....) and sometimes not. I have a hard time to know when to use the right one at the right time (the docs are a bit obscure on these points).
> Whereas in `defmacro', I know exactly when to use `quote' and `unquote'.


Some of it is like saying that "I grew up on C syntax and I really know where to put ()s there. With this Scheme syntax, I never know." 



> Wouldn't it be possible to define "safe" quotes and unquotes for syntax macros, without having to go from syntax to datum and vice-versa at weird places?
> I mean, syntax objects are encapsulating other data that I really don't need 99% of the time.
> So why should I bother about something I don't want?


And some of this is saying "I don't know that this information is used by the PLT tools (check syntax)" or "I don't care that most real PLT programmers rely on this information in syntax objects almost all the time I want it the Lisp way." 

-- Matthias




Posted on the users mailing list.