pystencils.backend.ast.astnode.PsAstNode#
- class pystencils.backend.ast.astnode.PsAstNode#
Base class for all nodes in the pystencils AST.
This base class provides a common interface to inspect and update the AST’s branching structure. The two methods
get_children
andset_child
must be implemented by each subclass. Subclasses are also responsible for doing the necessary type checks if they place restrictions on the types of their children.- abstract get_children()#
Retrieve child nodes of this AST node
This operation must be implemented by subclasses.
- abstract set_child(idx, c)#
Update a child node of this AST node.
This operation must be implemented by subclasses.