This is the mail archive of the kawa@sourceware.org mailing list for the Kawa project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: unquote in quasisyntax


On Feb 6, 2012, at 5:33 PM, Per Bothner wrote:

Aha, you want "identifier macros", like Dybvig's identifier-syntax
and make-variable-transformer. This feature is rather controversial,
but it is arguably part of "syntax-case" as a feature, and it appears
to be a R6RS feature if I understand make-variable-transformer correctly.


I haven't really looked into how difficult this would be to implement.
Specifically I don't know how deeply we'd have to dig into the macro
implementation (there be dragons ...).  I don't think it's a trivial
feature, and other non-trivial features (including patterns) are
higher priority.

Identifier macros are part of it, yes. But the R6RS standard libraries spec
says


A <pattern> is an identifier, constant, or one of the following.

(<pattern> ...)
(<pattern> <pattern> ... . <pattern>)
(<pattern> ... <pattern> <ellipsis> <pattern> ...)
(<pattern> ... <pattern> <ellipsis> <pattern> ... . <pattern>)
#(<pattern> ...)
#(<pattern> ... <pattern> <ellipsis> <pattern> ...)


So we're also missing constants and #() forms. I can't think of why you
would want to write a "constant macro", unless you want to do something
silly like read "22/7" as "java.lang.Math:PI".

To be clear, I don't consider any of this to be of high priority, I was
just pointing out differences between TSPL/R6RS's syntax-case and Kawa's.


--
Jamison Hope
The PTR Group
www.theptrgroup.com




Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]