The transform button is nice while developing a language, but what would be the best way for end users to generate code?

Options:

  • Hook into the Project > Build project menu. Requires a project nature (ugh) and under the hood lots of Java boilerplate.
  • Hook into the automatic build API. Requires a project nature and some form of incremental code generation, which is hard to implement for language developers.
  • Make it easier to invoke the code generator using Ant. Seems to be the most flexible option and best for integration with other tools.
  • ???

All options seem to require a “new project” wizard for the language for best usability. The wizard could set the project nature and/or create build files.

Relates to Spoofax/33: Add API to easily apply a builder on any editor or file

Submitted by Lennart Kats on 25 February 2010 at 08:21

On 25 February 2010 at 08:31 Lennart Kats commented:

see also Spoofax/25


On 4 March 2010 at 08:57 Zef Hemel commented:

How about a “Save file” hook to start off with? This largely enables you to emulate Eclipse’s Java behavior. And I’d guess it’s not that difficult to implement.


On 4 March 2010 at 09:13 Lennart Kats commented:

[edit]^ what he said. see Spoofax/38: Add an “on save” listener for lightweight code generation[/edit]


On 8 January 2013 at 16:26 Eelco Visser removed tag @lennartkats

On 8 January 2013 at 16:28 Eelco Visser tagged 1.2

On 1 February 2013 at 10:40 Guido Wachsmuth tagged @gohla

On 13 March 2014 at 08:53 Eelco Visser removed tag 1.2

Log in to post comments