> On Feb 19, 2019, at 2:33 PM, Brian Adkins <[email protected]> wrote:
> 
> Awesome - that did the trick. I'm confused as to why it helped to inject STR 
> into the lexical context - it ends up being just a string, and it was working 
> fine with respect to loading the template. I would think the fix would be to 
> inject include-template into the lexical context. I suppose it must have 
> something to do with how the include-template macro is dealing with that 
> argument. 

When `with-syntax` finds a datum (like a string) on the right side of a 
pattern-binding expression, it silently coerces it to a syntax object with the 
macro-definition scope attached (which in this case, was not the right scope).

Ordinarily you wouldn't want to move `include-template` into the lexical 
context of the calling site, because you're relying on retaining the binding it 
has at the macro-definition site.

-- 
You received this message because you are subscribed to the Google Groups 
"Racket Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to