There is a queue-analysis (which queues analysis for a particular file) and queue-strategy (which queues the execution of a strategy on a term) strategy now, but what I would like is to queue a particular strategy on a different file. A combination of both of these, as it were. I need this to trigger recompilation of files that depend on the file the user is editing.

Submitted by Zef Hemel on 7 July 2010 at 11:36

On 8 July 2010 at 15:46 Lennart Kats commented:

Nathan designed the queuing interface. Maybe he could comment on this issue?


On 8 July 2010 at 23:20 Nathan Bruning commented:

The simplest option would be to use queue-strategy, as it operates on a term and a project, not on any particular file. For example:

<queue-strategy(|"compile-file", "Compiling..."> "another-file.mylang"

compile-file = 
    parse-file
  ; compile-and-write

If you really need a queue-strategy that gives you the AST (like queue-analysis), you’ll need a combination of both strategies. Basically you’ll re-implement org.strategoxt.imp.runtime.services.StrategoObserverBackgroundUpdateJob, changing

observer.update(parseController, monitor);

to

observer.invoke(strategyName, term, project);

On 16 July 2010 at 11:51 Zef Hemel commented:

Ah, so this is already possible. Good, I’ll look into it.


On 8 January 2013 at 17:06 Gabriël Konat closed this issue.

Log in to post comments