|
|
|
|
|
by dherman
5013 days ago
|
|
> Ok, so are you are concerned with the case where the person defining the macro uses a symbol from the namespace of the person using the macro but that symbol has been rebound by the user inside of a let surrounding the aforementioned usage of the macro? > If so, that requires a cyclic module dependency... Not necessarily. For example (forgive the Scheme syntax), all in one module: (define thing "outer thing")
;; define-inline is the above macro-defining-macro
(define-inline (foo prefix)
(string-append prefix thing))
(let ((thing "inner thing"))
(foo "should say outer thing: "))
|
|
(edit:) Alternatively, maybe you are focussing on the define-inline "macro-defining macro"; you mentioned it here again as "the above", and you had used it above, but as it wasn't defined it didn't seem important. I tried to go ahead and implement it, although to be honest I feel like I did it wrong (spending more time thinking about it, I believe it is correct, modulo your definition of "inline"); that said, it "worked".
"should say outer thing: outer thing"