[plt-scheme] require-for-syntax and syntax/parse

From: Jon Rafkind (rafkind at cs.utah.edu)
Date: Tue Sep 15 12:37:03 EDT 2009

>
> With very few exceptions, "library" modules like syntax/parse export 
> all of their bindings at phase 0 (the normal environment). So add 
> 'for-syntax' to make them available to macros.
>
> Modules that provide things for-syntax are the exception rather than 
> the rule, except for languages modules like 'scheme', which provide 
> everything at phase 0 (normal) and phase 1 (for-syntax). I would 
> expect individual bindings provided for-syntax to be marked as such in 
> the documentation.
>

A sort of nutty idea but maybe when a binding can't be found in the 
current phase, the other phases could be checked for it. If found a 
message could be printed like "<binding> found in phase X from module 
Y". Maybe errortrace or something like it could do this. I don't know if 
this is even possible but it would be helpful occasionally.


Posted on the users mailing list.