Skip to content
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

[AST-Refactor] AccessNode removed #1548

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

ThakeeNathees
Copy link
Collaborator

@ThakeeNathees ThakeeNathees commented Feb 1, 2025

Description

This AccessNode is an abstract type of the AST, however, in the new AST (which is being refactored) it'll only be Expression and Statement abstract class, and we'll be removing everything else.

NOTE: Once all the dependent nodes of SubTag are removed, SubTag will also be removed.

@@ -215,7 +215,11 @@ def global_var(self, kid: list[ast.AstNode]) -> ast.GlobalVars:
global_var: (KW_LET | KW_GLOBAL) access_tag? assignment_list SEMI
"""
is_frozen = isinstance(kid[0], ast.Token) and kid[0].name == Tok.KW_LET
access = kid[1] if isinstance(kid[1], ast.SubTag) else None
access = (
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

NOTE: SubTag will be removed and the token will be handled properly, for now I'm doing a type ignore since SubTag's tag is a generic type (Not token).

@ThakeeNathees ThakeeNathees added jaclang Issues related to jac programming language refactor labels Feb 4, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
jaclang Issues related to jac programming language refactor
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants