Queue strategy on file (1)
There is aSubmitted by Zef Hemel on 7 July 2010 at 11:36
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.
Nathan designed the queuing interface. Maybe he could comment on this issue?
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-strategythat gives you the AST (like
queue-analysis), you’ll need a combination of both strategies. Basically you’ll re-implement
observer.invoke(strategyName, term, project);
Ah, so this is already possible. Good, I’ll look into it.
Log in to post comments