symtable.SymbolTable.has_children()

has_children() Return True if the block has nested namespaces within it. These can be obtained with get_children().

symtable.SymbolTable.get_type()

get_type() Return the type of the symbol table. Possible values are 'class', 'module', and 'function'.

symtable.SymbolTable.get_symbols()

get_symbols() Return a list of Symbol instances for names in the table.

symtable.SymbolTable.get_name()

get_name() Return the table’s name. This is the name of the class if the table is for a class, the name of the function if the table is for a function, or 'top' if the table is global (get_type() returns 'module').

symtable.SymbolTable.get_lineno()

get_lineno() Return the number of the first line in the block this table represents.

symtable.SymbolTable.get_identifiers()

get_identifiers() Return a list of names of symbols in this table.

symtable.SymbolTable.get_id()

get_id() Return the table’s identifier.

symtable.SymbolTable.get_children()

get_children() Return a list of the nested symbol tables.

symtable.SymbolTable

class symtable.SymbolTable A namespace table for a block. The constructor is not public. get_type() Return the type of the symbol table. Possible values are 'class', 'module', and 'function'. get_id() Return the table’s identifier. get_name() Return the table’s name. This is the name of the class if the table is for a class, the name of the function if the table is for a function, or 'top' if the table is global (get_type() returns 'module'). get_lineno() Return the numb

symtable.Symbol.is_referenced()

is_referenced() Return True if the symbol is used in its block.