Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

EndConversationStatement object has wrong FirstTokenIndex value

Open
#90 2 comments 5 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
3/5
Estimated time
1-2 days
Newbie friendliness
45/100
Issue type
Bug
Clarity
Mostly clear
Activity status
Stale
Tech stack
sql
Domain
compilers

Research direction

Start by reproducing the issue with the END CONVERSATION @handle; example using ScriptDom compatibility level 150, then inspect the parsed EndConversationStatement object. Compare FirstTokenIndex with the END token and LastTokenIndex with the semicolon; done means FirstTokenIndex identifies END while the existing last-token behavior remains correct.

Written by the indexing model from the issue text.

Description

ScriptDom version: 161.9123
Parser compatibility level: 150

Code example

END CONVERSATION @handle;

Actually, I noticed it on a longer IF-ELSE-END CONVERSATION piece of code, but here is the problem: FirstTokenIndex points not to END keyword but to @handle variable reference which is wrong. On screenshot below FirstTokenIndex should be 178, not 182.

image

LastTokenIndex points here to semicolon position which is correct.

Dominant language
GAP
Stars
277
Forks
43
Avg merge
6d 17h
Merged PRs (30d)
3

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from microsoft/SqlScriptDOM

All issues in microsoft/SqlScriptDOM

Similar issues

More Compilers issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.