Skip to content

Commit

Permalink
Ability defs not make more sense from a sym tab perspecitive
Browse files Browse the repository at this point in the history
  • Loading branch information
marsninja committed Sep 16, 2023
1 parent 003be7f commit 8d0fd4c
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions jaclang/jac/passes/blue/sym_tab_build_pass.py
Original file line number Diff line number Diff line change
Expand Up @@ -283,8 +283,21 @@ def enter_ability_def(self, node: ast.AbilityDef) -> None:
single=True,
):
self.already_declared_err(ability_name, "ability def", collide)
self.cur_sym_tab = self.cur_sym_tab.push_scope()
node.sym_tab = self.cur_sym_tab

def exit_ability_def(self, node: ast.AbilityDef) -> None:
"""Sub objects.
doc: Optional[Token],
target: Optional[DottedNameList],
ability: ArchRef,
signature: FuncSignature | EventSignature,
body: CodeBlock,
sym_tab: Optional[SymbolTable],
"""
self.cur_sym_tab = self.cur_sym_tab.parent

def enter_event_signature(self, node: ast.EventSignature) -> None:
"""Sub objects.
Expand Down

0 comments on commit 8d0fd4c

Please sign in to comment.