Skip to content

fix(common): #424 allTokens slice when caretTokenIndex use tokenIndexOffset #426

New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Merged
merged 2 commits into from
Jun 5, 2025

Conversation

liuxy0551
Copy link
Collaborator

原因:在出现错误时,caretTokenIndex 进行了 tokenIndexOffset 的调整而 allTokens 没有进行相应调整

另外由于 slice 的第二个参数 end 的特性,当 stopStatement 为 null 时,end 不需要在 sql 长度的基础上 -1,这可能会影响补全的准确性。

@liuxy0551 liuxy0551 marked this pull request as draft May 30, 2025 01:53
@liuxy0551 liuxy0551 marked this pull request as ready for review May 30, 2025 03:19
@qinyouzhi
Copy link

发布窗口是什么时候

Copy link
Collaborator

@Cythia828 Cythia828 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

+1

@mumiao mumiao merged commit 616dc11 into DTStack:main Jun 5, 2025
6 checks passed
@mumiao
Copy link
Collaborator

mumiao commented Jun 5, 2025

发布窗口是什么时候

released: dt-sql-parser@4.3.1

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants