pydoc > symtable

📛 NAME

symtable - Interface to the compiler's internal symbol tables

🚀 Quick Reference

Use CaseCommandDescription
Parse source codesymtable.symtable(code, filename, compile_type)Return top-level SymbolTable for the code
Get all symbolstable.get_symbols()List of Symbol instances in the table
Lookup a nametable.lookup('name')Return Symbol for the given name
Check symbol scopesym.is_global()Return True if the symbol is global
Get table typetable.get_type()Returns 'class', 'module', or 'function'
Get class methodsclass_table.get_methods()Tuple of method names declared in the class
Get function localsfunc_table.get_locals()Tuple of local variable names
Get function globalsfunc_table.get_globals()Tuple of global variable names
Get nested tablestable.get_children()List of child symbol tables

📚 MODULE REFERENCE

https://docs.python.org/3.10/library/symtable.html

The following documentation is automatically generated from the Python source files. It may be incomplete, incorrect or include features that are considered implementation detail and may vary between Python implementations. When in doubt, consult the module reference at the location listed above.

🏛️ CLASSES

🏛️ class Class(SymbolTable)

Class(raw_table, filename)

Method resolution order:

✨ Methods defined here

⚙️ Methods inherited from SymbolTable

📦 Data descriptors inherited from SymbolTable

🏛️ class Function(SymbolTable)

Function(raw_table, filename)

Method resolution order:

✨ Methods defined here

⚙️ Methods inherited from SymbolTable

📦 Data descriptors inherited from SymbolTable

🔣 class Symbol(builtins.object)

Symbol(name, flags, namespaces=None, *, module_scope=False)

✨ Methods defined here

📦 Data descriptors defined here

📋 class SymbolTable(builtins.object)

SymbolTable(raw_table, filename)

✨ Methods defined here

📦 Data descriptors defined here

🔧 FUNCTIONS

🔧 symtable()

📦 DATA

__all__ = ['symtable', 'SymbolTable', 'Class', 'Function', 'Symbol']

📁 FILE

/usr/lib/python3.10/symtable.py

symtable
📛 NAME 🚀 Quick Reference 📚 MODULE REFERENCE 🏛️ CLASSES
🏛️ class Class(SymbolTable) 🏛️ class Function(SymbolTable) 🔣 class Symbol(builtins.object) 📋 class SymbolTable(builtins.object)
🔧 FUNCTIONS
🔧 symtable()
📦 DATA 📁 FILE

Generated by phpman v4.9.27 · Markdown · JSON · MCP Author: Che Dong Under GNU General Public License
2026-07-18 13:15 @216.73.216.114
CrawledBy Mozilla/5.0 AppleWebKit/537.36 (KHTML, like Gecko; compatible; ClaudeBot/1.0; +claudebot@anthropic.com)
Valid XHTML 1.0 Transitional!Valid CSS!
Enhanced by LLM: deepseek-v4-flash / taotoken.net / www.chedong.com - original format

^_top_^