Skip to content

Commit

Permalink
fix: update error handling for unsupported walk in compileError function
Browse files Browse the repository at this point in the history
  • Loading branch information
tolgaOzen committed Sep 18, 2024
1 parent 0f1b552 commit 73842a7
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pkg/dsl/compiler/compiler.go
Original file line number Diff line number Diff line change
Expand Up @@ -486,7 +486,7 @@ func (t *Compiler) compileCall(entityName string, call *ast.Call) (*base.Child,

// If the argument has more than two identifiers, it indicates an unsupported relation walk.
// Return an error in this case.
return nil, compileError(argument.Idents[2].PositionInfo, base.ErrorCode_ERROR_CODE_NOT_SUPPORTED_WALK.String())
return nil, compileError(argument.Idents[1].PositionInfo, base.ErrorCode_ERROR_CODE_NOT_SUPPORTED_WALK.String())
}

// Set the child's type to be a leaf with the compiled call information.
Expand Down

0 comments on commit 73842a7

Please sign in to comment.