Skip to content

symbol ¤

Looking up addresses for function names / symbols, and vice-versa.

Classes:

Functions:

Attributes:

skipped_exceptions module-attribute ¤

skipped_exceptions = ('No frame selected', 'Cannot find thread-local')

DOMAIN_MAPPING module-attribute ¤

DOMAIN_MAPPING = {
    ANY: SYMBOL_VAR_DOMAIN,
    VARIABLE: SYMBOL_VAR_DOMAIN,
    FUNCTION: SYMBOL_FUNCTION_DOMAIN,
}

order_prefs module-attribute ¤

order_prefs = {
    True: (
        _global_static_symbol_to_address,
        _global_exported_symbol_to_address,
    ),
    False: (
        _global_exported_symbol_to_address,
        _global_static_symbol_to_address,
    ),
}

Domain ¤

Bases: Enum

Methods:

Attributes:

ANY class-attribute instance-attribute ¤

ANY = 1

VARIABLE class-attribute instance-attribute ¤

VARIABLE = 2

FUNCTION class-attribute instance-attribute ¤

FUNCTION = 3

validate ¤

validate(sym: Symbol) -> bool

resolve_addr ¤

resolve_addr(address: int) -> str

Retrieve the name for the symbol located at address Empty string if no symbol

lookup_symbol ¤

lookup_symbol(
    name: str,
    *,
    prefer_static: bool = False,
    domain: Domain = ANY,
    objfile_endswith: str | None = None,
) -> Value | None

Get the address for symbol

lookup_frame_symbol ¤

lookup_frame_symbol(name: str, *, domain: Domain = ANY) -> Value | None

Get the address for local symbol from frame, in most time you don't need it