Steps to reproduce:

Take the EntityLang generated by the wizard. Replace the context-free syntax with:

context-free syntax

Definition*   -> Start {cons("Module")}
"{" Part1 "}" -> Definition {cons("Def")}
"part1"       -> Part1 {cons("Part1")}

Replace the example module with:


Now put the cursor after the p and hit ctrl+space to trigger completion.

This will raise the following NPE:

Internal parsing error: null
at org.spoofax.jsglr.client.NewStructureSkipper.readLine(
at org.spoofax.jsglr.client.NewStructureSkipper.readLine(
at org.spoofax.jsglr.client.NewStructureSkipper.isScopeClosingLine(
at org.spoofax.jsglr.client.NewStructureSkipper.findParentBegin(
at org.spoofax.jsglr.client.NewStructureSkipper.getParentSkipSuggestions(
at org.spoofax.jsglr.client.RegionRecovery.selectErroneousFragment(
at org.spoofax.jsglr.client.RecoveryConnector.combinedRecover(
at org.spoofax.jsglr.client.RecoveryConnector.recover(
at org.spoofax.jsglr.client.SGLR.sglrParse(
at org.spoofax.jsglr.client.SGLR.parse(
at org.strategoxt.imp.runtime.parser.JSGLRI.doParse(
at org.strategoxt.imp.runtime.parser.AbstractSGLRI.parse(
at org.strategoxt.imp.runtime.parser.SGLRParseController.doParse(
at org.strategoxt.imp.runtime.parser.SGLRParseController.parse(
at org.strategoxt.imp.runtime.parser.SGLRParseController.parse(
at org.strategoxt.imp.runtime.dynamicloading.DynamicParseController.parse(

Note: This happens only if there is indentation on the line where completion is triggered. When there is no indentation, there is no NPE.

Edit: This is with Spoofax r22419.

Submitted by Tobi Vollebregt on 22 March 2011 at 12:53

On 22 March 2011 at 13:02 Lennart Kats tagged @maartje

On 22 March 2011 at 13:02 Lennart Kats tagged error

On 22 March 2011 at 13:02 Lennart Kats tagged parser

On 23 March 2011 at 14:55 Tobi Vollebregt tagged completion

On 30 March 2011 at 14:33 Tobi Vollebregt removed tag completion

On 19 September 2011 at 20:07 Tobi Vollebregt commented:

An easier way to reproduce in this duplicate:

On 20 September 2011 at 16:15 Maartje closed this issue.

On 20 September 2011 at 16:15 Maartje commented:

bug fixed

On 17 October 2011 at 17:37 Lennart Kats tagged completion

On 22 December 2011 at 16:50 Lennart Kats tagged 1.0

Log in to post comments