New Javascript language for MPS or... a sort of. Follow
Hi,
I just published what I developped so far during the last days.
It's an implementation of Javascript (ECMAScript 5.1) that I would like to use to generate Javascript after further improvements.
Here you can find the github project https://github.com/mar9000/ecmascript4mps
and here a small presentation http://mar9000.org/bliki/ecma-script-4-mps.html
I saw a similar project on github but it's quite old and probably less complete then mine with respect to supported constructs. ECMAScript4MPS is complete with respect to supported syntax.
It's just a draft work I know. I think to improve it in the future at least to make it usable in generation templates.
I would like to thank people from this forum who helped me when I did not have a clue.
Mainly Vaclav.
Mar
I just published what I developped so far during the last days.
It's an implementation of Javascript (ECMAScript 5.1) that I would like to use to generate Javascript after further improvements.
Here you can find the github project https://github.com/mar9000/ecmascript4mps
and here a small presentation http://mar9000.org/bliki/ecma-script-4-mps.html
I saw a similar project on github but it's quite old and probably less complete then mine with respect to supported constructs. ECMAScript4MPS is complete with respect to supported syntax.
It's just a draft work I know. I think to improve it in the future at least to make it usable in generation templates.
I would like to thank people from this forum who helped me when I did not have a clue.
Mainly Vaclav.
Mar
Please sign in to leave a comment.
You mention a desire to write a developer guide in your blog post. What topics would you like to cover?
Yes I think to migrate to 3.2, I'll make a try one of these days.
With respect to documentation I would like, also as a way to organize my knowledge, to highlight a series of pattern that could help passing from grammar description (ANTLR, EBNF, PEG...) to the aspects you need to implement the same edit in projectional editing.
In theory that piece of a language that is "text editing" should be derived from its grammar.
I don't have the background to do it in a exhaustive way so... I don't how far I'll get.
In this sense should then be interesting to highlight some of these patterns in this, and in future versions, of ECMAScript4MPS.
BTW, we're experimenting with a grammar-like editor definition language for one of the future MPS releases.
Indeed, as Vaclav said, we're currently working exactly on the mechanism of deriving editing behaviour from not really grammar but a very grammar-like description. If you're into it then it would be great if you posted some update here from time to time. Even if it's only a link to a blog post, or something.
I am also interested in better integration between parsing technology and projectional editing in MPS and would be happy to discuss and share ideas.
I don't feel I can help you guys at MPS :-) but I'll be happy to share my progess, the ECMAScript4MPS project does not have any internal/non-public part.
@Fabien: in case I'll post here, and switch to somethingelse as soon it will be set up.
I am thinking in addition to editing behavior, there are precedents to annotating a grammar to indicate how to populate an AST. For instance, see http://www.irisa.fr/caps/people/hardy/m1comp/doc/trees.html for a (arguably convoluted) description of how ANTLR manages to do that.
I am wondering if it would be possible to generate most of a language from a grammar, with specialized annotations. I personally prefer to develop languages the MPS way, but if a grammar is available, I would not mind having a simpler way to obtain an MPS language for that language than to re-implement everything from scratch.