| Binary code generation with Xtend/Xpand/Xtend2? [message #647196]
||Tue, 04 January 2011 19:06
| Mirko Raner
Registered: July 2009
Location: San Diego, CA
we have an Xtext grammar and an EMF model generated from that grammar, and now we want to generate binary code (similar to Java bytecode, for example).
It's obviously not a big deal to write some simple visitor that traverses the EMF model and spits out a sequence of bytes, but we're wondering whether we could leverage Xtend/Xpand or Xtend2 to perform the code generation.
So far, it seems like the code generation is geared towards generating other source code (not binaries). We understand that we could generate Java code that, in turn, generates the binary code, but if direct binary code generation is possible we might consider that option over a hand-written EMF-to-binary generator.
Any insights on this? Can Xtend/Xpand/Xtend2 be used for that purpose or are we better off with a hand-rolled code generator?
Powered by FUDForum
. Page generated in 0.01780 seconds