I would be helpful to have Spoofax be able to drop to a debugger when the “with clause failed unexpectedly”.

Submitted by Dobes Vandermeer on 19 November 2012 at 18:26

On 20 November 2012 at 10:26 Gabriël Konat commented:

There is a debugger: http://strategoxt.org/Spoofax/DebugStratego. It works by instrumenting your Stratego code with debug information, so you have to generate instrumented code every time you wish to debug. I don’t think it supports dropping to a debugger when there is a with failure.


On 20 November 2012 at 14:15 Emmanuel Castro commented:

However, the debugger does not work.
In r25724, compilation fails on:
[javac] 1. ERROR in /home/ecastro/workspace.trunk2/Type/editor/java/trans/index_parallel_analyze_1_0.java (at line 55)
[javac] term = parallel_unordered_1_0.instance.invoke(context, term, lifted5990);

I tried removing the index-parallel call, and following the procedure in the URL above, without success.


On 20 November 2012 at 22:28 Dobes Vandermeer commented:

Ah sorry, I didn’t notice that page! I seem to get a bit lost in the docs sometimes, bear with me.

For catching a “with” failure I might be able to put a breakpoint into a special failure rule of my own.


On 20 November 2012 at 22:58 Gabriël Konat commented:

index-parallel is used in a generated library which gets regenerated at build, so that might be why removing that doesn’t work. parallel-unordered is from the stratego-parallel library, maybe that needs to be included somehow? Haven’t used the debugger myself yet so not sure how that works.

For Spoofax projects this is done by changing the build.stratego.args property in build.main.xml to link to stratego-parallel like so:

<property name="build.stratego.args" value="
    --library
    -I &quot;${trans}&quot;
    -I &quot;${basedir}&quot;
    -la stratego-lib -la stratego-parallel -la stratego-sglr -la stratego-gpp -la stratego-xtc -la stratego-aterm"/>

On 8 January 2013 at 13:49 Eelco Visser commented:

That’s what we (should) have the Stratego debugger for; see https://yellowgrass.org/issue/Stratego/2


On 8 January 2013 at 13:49 Eelco Visser closed this issue.

Log in to post comments