Skip to content

Commit df323a5

Browse files
committed
Fix source mapping for code snippets
Signed-off-by: Ben Sherman <bentshermann@gmail.com>
1 parent 99ce102 commit df323a5

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

modules/compiler/src/main/java/script/parser/ScriptAstBuilder.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -228,6 +228,7 @@ private ModuleNode compilationUnit(CompilationUnitContext ctx) {
228228

229229
if( !statements.isEmpty() ) {
230230
var main = block(new VariableScope(), statements);
231+
ast( main, statements.get(0), statements.get(statements.size() - 1) );
231232
var workflowNode = workflowDef(main);
232233
moduleNode.addWorkflow(workflowNode);
233234
if( !hasDeclarations )

0 commit comments

Comments
 (0)