Skip to content

fix: updates to grammars/scanners to fix bugs found in healthshare te… - #54

Merged
hkimura-intersys merged 4 commits into
intersystems:mainfrom
hkimura-intersys:v1.9.17-updates
Aug 31, 2026
Merged

fix: updates to grammars/scanners to fix bugs found in healthshare te…#54
hkimura-intersys merged 4 commits into
intersystems:mainfrom
hkimura-intersys:v1.9.17-updates

Conversation

@hkimura-intersys

Copy link
Copy Markdown
Member

This PR fixes errors found when testing tree-sitter with files from //projects/healthshare/
Changes:
1. Add ZenMethod keyword, missing relationship keywords,
2. Added ClientMethod (also known as ClassClientMethod)
3. Allow do with a macro
4. Allow statements to be a macro arg
5. Allow macros as json literals
6. Change parsing of ZW_BLOCK and ARGUMENTLESS_LOOP in scanner to account for if {hi} {} cases
7. Combined external language parsing into one function, and used flags to differentiate when needed.
8. Parse mimetype with scanner and token (scanner for python or text to set needed flags).
9. Allowed optional argument in property
10. Add #EXECUTE to statement options
11. Allow macro.prop as class name
12. Allow #IF, #ENDIF, #ELSE to start on any col
13. Allow macros in oref_chain_segment
14. allow () in foreignkey without the index name
15. Fix parsing Property with arguments
16. Fix Index Type parsing
17. Allow * as a arg to a macro function
18. Allow macro.prop as class name

The updated grammars/scanners have been tested on all files in //projects/healthshare as well as all files in %SYS and //projects/sql

…sting.

Errors fixed:
	1. Add ZenMethod keyword, missing relationship keywords,
	2. Added ClientMethod (also known as ClassClientMethod)
	3. Allow do with a macro
	4. Allow statements to be a macro arg
	5. Allow macros as json literals
	6. Change parsing of ZW_BLOCK and ARGUMENTLESS_LOOP in scanner to account for if {hi} {} cases
	7. Combined external language parsing into one function, and used flags to differentiate when needed.
	8. Parse mimetype with scanner and token (scanner for python or text to set needed flags).
	9. Allowed optional argument in property
	10. Add #EXECUTE to statement options
	11. Allow macro.prop as class name
	12. Allow #IF, #ENDIF, #ELSE to start on any col
	13. Allow macros in oref_chain_segment
	14. allow () in foreignkey without the index name
	15. Fix parsing Property with arguments
	16. Fix Index Type parsing
	17.  Allow * as a arg  to a macro function
	18. Allow macro.prop as class name
@hkimura-intersys hkimura-intersys self-assigned this Aug 31, 2026
@hkimura-intersys
hkimura-intersys requested review from davem-intersys and removed request for davem-intersys August 31, 2026 13:18
@hkimura-intersys
hkimura-intersys merged commit e2193fd into intersystems:main Aug 31, 2026
11 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant