psyclone.psyir.nodes.member#
This module contains the implementation of the Member node.
Classes#
Member: Node representing a membership expression of a structure.
- class psyclone.psyir.nodes.member.Member(member_name, parent=None)[source]#
Node representing a membership expression of a structure. As such it is a leaf in the PSyIR tree.
- Parameters:
member_name (str) – the name of the member of the structure that is being referenced.
parent (
psyclone.psyir.nodes.StructureReferenceorpsyclone.psyir.nodes.Member) – the parent of this node in the PSyIR tree.
- Raises:
TypeError – if the supplied parent is of the wrong type.
Inheritance

- get_base_and_depth()[source]#
- Returns:
the base Reference that contains this member and the depth where this member is found.
- Return type:
tuple[ Optional[
psyclone.psyir.node.StructureReference], int]
- get_signature_and_indices()[source]#
- Returns:
the Signature of this member access, and a list of list of the indices used for each component, which is empty in this case since it is not an array access.
- Return type:
tuple[
psyclone.core.Signature, List[List[int]]]
- property name#
- Returns:
the name of this member.
- Return type:
str