On 9/2/10 2:23 PM, Jonathan S. Shapiro wrote: > *First-Class Syntax* > > The evident *problem* with my view is that you sometimes (lexically) inherit > operator bindings or precedence choices that don't work for your specialized > embedded language, and there isn't really a way to get rid of them. It seems > to me that the right solution here is to introduce a notion of a "syntax > table", so that you can write something like: > > with syntax *mySyntax* > *sequence of forms* > > The interpretation of a mixfix introduction is that it modifies the current, > lexically-prevailing syntax.
I don't know that anything has been published on it, but you should talk with Jason Eisner about Jay's parser for Dyna. It does a lot of this sort of chicanery, so they've charted the territory at least. There's also the caml4p approach which I think is horrific, since it makes it trivial to break the syntax of the language and almost impossible to do anything non-trivial without breakage. That's why my Coq code is all done in S-expressions whenever possible. It's an anti-pattern to bear in mind. -- Live well, ~wren _______________________________________________ bitc-dev mailing list [email protected] http://www.coyotos.org/mailman/listinfo/bitc-dev
