On this page
  1. symtable.Function
  2. Import
  3. Signature & Overview
  4. Methods & Attributes
  5. Usage
  6. Gotchas
  7. REPL Inspect

symtable.Function

Prev: symtable.Class | Up: symtable | Next: symtable.Symbol
Rel: symtable.Class, symtable.Symbol, symtable.SymbolTable, symtable.SymbolTableType
Ref: docs.python.org — symtable.Function
Tags: #public #python3 #stdlib #symtable


Import

import symtable
from symtable import Function

Signature & Overview

symtable.Function(raw_table, filename)

symtable.Function class.

Methods & Attributes

Usage

import symtable

tbl = symtable.symtable('def f(a): b = a + 1', '<m>', 'exec')
fn_tbl = tbl.get_children()[0]
assert isinstance(fn_tbl, symtable.Function) and fn_tbl.get_parameters() == ('a',)

Gotchas

REPL Inspect

from symtable import Function
help(Function)

Linked from

Related notes