Skip to content

nearpc ¤

Functions:

Attributes:

c module-attribute ¤

c = ColorConfig(
    "nearpc",
    [
        ColorParamSpec("symbol", "normal", "color for nearpc command (symbol)"),
        ColorParamSpec(
            "address", "normal", "color for nearpc command (address)"
        ),
        ColorParamSpec(
            "prefix", "none", "color for nearpc command (prefix marker)"
        ),
        ColorParamSpec(
            "breakpoint", "red", "color for nearpc command (breakpoint marker)"
        ),
        ColorParamSpec(
            "syscall-name",
            "red",
            "color for nearpc command (resolved syscall name)",
        ),
        ColorParamSpec(
            "argument", "bold", "color for nearpc command (target argument)"
        ),
        ColorParamSpec(
            "integration-comments",
            "bold",
            "color for nearpc command (integration comments)",
        ),
        ColorParamSpec(
            "branch-marker",
            "normal",
            "color for nearpc command (branch marker line)",
        ),
    ],
)

nearpc_branch_marker module-attribute ¤

nearpc_branch_marker = add_param(
    "nearpc-branch-marker", "    ↓", "branch marker line for nearpc command"
)

nearpc_branch_marker_contiguous module-attribute ¤

nearpc_branch_marker_contiguous = add_param(
    "nearpc-branch-marker-contiguous",
    " ",
    "contiguous branch marker line for nearpc command",
)

nearpc_lines module-attribute ¤

nearpc_lines = add_param(
    "nearpc-lines",
    10,
    "number of additional lines to print for the nearpc command",
)

show_args module-attribute ¤

show_args = add_param(
    "nearpc-show-args", True, "whether to show call arguments below instruction"
)

show_comments module-attribute ¤

show_comments = add_param(
    "nearpc-integration-comments",
    True,
    "whether to show comments from integration provider",
)

show_opcode_bytes module-attribute ¤

show_opcode_bytes = add_param(
    "nearpc-num-opcode-bytes",
    0,
    "number of opcode bytes to print for each instruction",
    param_class=PARAM_ZUINTEGER,
)

opcode_separator_bytes module-attribute ¤

opcode_separator_bytes = add_param(
    "nearpc-opcode-separator-bytes",
    1,
    "number of spaces between opcode bytes",
    param_class=PARAM_ZUINTEGER,
)

ljust_padding ¤

ljust_padding(lst)

nearpc ¤

nearpc(
    pc: int = None,
    lines: int = None,
    emulate=False,
    repeat=False,
    use_cache=False,
    linear=False,
) -> list[str]

Disassemble near a specified address.

The linear argument specifies if we should disassemble linearly in memory, or take jumps into account