class documentation

class Def(object): (source)

Constructor: Def(node)

View In Hierarchy

Model a definition, either named or unnamed, and its users.

Method __init__ Undocumented
Method __repr__ Undocumented
Method __str__ Undocumented
Method add_user Undocumented
Method isdel Undocumented
Method name If the node associated to this Def has a name, returns this name. Otherwise returns its type
Method users The list of ast entity that holds a reference to this node
Class Variable __slots__ Undocumented
Instance Variable islive Whether this definition might reach the final block of it's scope. Meaning if islive is False, the definition will always be overriden at the time we finished executing the module/class/function body. ...
Instance Variable node Undocumented
Method _repr Undocumented
Method _str Undocumented
Instance Variable _users Undocumented
def __init__(self, node): (source)

Undocumented

def __repr__(self): (source)

Undocumented

def __str__(self): (source)

Undocumented

def add_user(self, node): (source)

Undocumented

def isdel(self): (source)

Undocumented

def name(self): (source)

If the node associated to this Def has a name, returns this name. Otherwise returns its type

def users(self): (source)

The list of ast entity that holds a reference to this node

__slots__: tuple[str, ...] = (source)

Undocumented

Whether this definition might reach the final block of it's scope. Meaning if islive is False, the definition will always be overriden at the time we finished executing the module/class/function body. So the definition could be ignored in the context of an attribute access for instance.

Undocumented

def _repr(self, nodes): (source)

Undocumented

def _str(self, nodes): (source)

Undocumented

Undocumented