-
-
Notifications
You must be signed in to change notification settings - Fork 2.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
highlight(sql): Update tree-sitter-sql to 98a7fc9
#7387
Conversation
92018a3
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks!
Yeah as you noted in the issue it looks like that node is unused. When the tree-sitter C library checks the queries ("query analysis") it will reject patterns that can't possibly match. When it says that for named nodes that exist in the |
I'll add one more patch, since DerekStride/tree-sitter-sql#154 got fixed.
Thanks! |
I pushed e401a61 which only fixes a I updated the PR title, description and hyperlinks to reflect the addition. The referenced commit |
92018a3
98a7fc9
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks!
* highlight(sql): Update tree-sitter-sql to 92018a3 * highlight(sql): Update tree-sitter-sql to 98a7fc9
* highlight(sql): Update tree-sitter-sql to 92018a3 * highlight(sql): Update tree-sitter-sql to 98a7fc9
* highlight(sql): Update tree-sitter-sql to 92018a3 * highlight(sql): Update tree-sitter-sql to 98a7fc9
Changes:
Updates
tree-sitter-sql
from3a3f92b29c880488a08bc2baaf1aca6432ec3380
toc5b1548ec95956c8da6393dceacf30aa349a6e9f
.Full
grammar.js
.Note that to avoid further diff noise, the tree sitter JSON and C sources were moved onto the
gh-pages
branch.This is why
languages.toml
references DerekStride/tree-sitter-sql@7cbac04 on thegh-pages
branch, which contains the sources for DerekStride/tree-sitter-sql@98a7fc9 on themain
branch (the latest grammar change onmain
).Merged PRs:
<>
expression to grammar DerekStride/tree-sitter-sql#112binary
andstring
datatypes for hive DerekStride/tree-sitter-sql#116default_timestamp
option DerekStride/tree-sitter-sql#123check option
as extra keyword nodes (for better highlighting) DerekStride/tree-sitter-sql#125full outer
joins DerekStride/tree-sitter-sql#130frame_definition
of window functions DerekStride/tree-sitter-sql#131key_constraint
DerekStride/tree-sitter-sql#136count
in favour ofinvocation
DerekStride/tree-sitter-sql#143insert overwrite
from spark sql DerekStride/tree-sitter-sql#148ERROR
DerekStride/tree-sitter-sql#157(Solved) Issue with
keyword_language
During review you might notice that
(keyword_language)
is commented out in line 210.It seems to me like this query should work, but as long as this keyword query is enabled, helix fails parsing with:
This seems to be a
TSQueryError
from tree-sitter's Cts_query_new
.The symbol is defined in
grammar.json
.But it is not defined in
node-types.json
.In
parser.c
, it is defined asaux_sym_keyword_language_token1
. 🤔 (see also the codegen)(keyword_language)
appears to be unused and thus declassified by the tree-sitter codegen to an auxiliary symbol.Disabling
(keyword_language)
in the queries list is a viable workaround. I'd completely remove it if it is removed upstream.