-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Python tree-sitter to CAST Porting: Imports (#826)
This PR introduces support for generating CAST import statements. This is using tree sitter, as part of the ongoing effort to port over the Python AST to CAST generation to use tree-sitter. ### Summary of Changes - Adds handlers to python/ts2cast.py to support CAST generation for import statements. - Adds basic CAST generation for the attribute idiom. In order to support function calls from imports. - Adds test script test_import_cast.py with unit tests to maintain consistency. - Added 'support' for yields and assert statements. The current generation is to passthrough them, so nothing important gets generated from these. ### Related issues - Resolves #804 --------- Co-authored-by: Vincent Raymond <vincent@lum.ai> 102dd72
- Loading branch information
1 parent
0e4a801
commit 7d60fc5
Showing
2,487 changed files
with
243,144 additions
and
218,931 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
508 changes: 490 additions & 18 deletions
508
api/python/skema/program_analysis/CAST/python/ts2cast.html
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.