GDB (xrefs)
|
Classes | |
class | DisablePrettyPrinter |
class | EnablePrettyPrinter |
class | InfoPrettyPrinter |
Functions | |
parse_printer_regexps (arg) | |
printer_enabled_p (printer) | |
count_enabled_printers (pretty_printers) | |
count_all_enabled_printers () | |
pluralize (text, n, suffix="s") | |
show_pretty_printer_enabled_summary () | |
do_enable_pretty_printer_1 (pretty_printers, name_re, subname_re, flag) | |
do_enable_pretty_printer (arg, flag) | |
register_pretty_printer_commands () | |
GDB commands for working with pretty-printers.
gdb.command.pretty_printers.count_all_enabled_printers | ( | ) |
Return a 2-tuble of the enabled state and total number of all printers. This includes subprinters.
Definition at line 201 of file pretty_printers.py.
References gdb.command.pretty_printers.count_enabled_printers(), gdb.current_progspace(), and gdb.objfiles().
Referenced by gdb.command.pretty_printers.InfoPrettyPrinter.invoke(), and gdb.command.pretty_printers.show_pretty_printer_enabled_summary().
gdb.command.pretty_printers.count_enabled_printers | ( | pretty_printers | ) |
Return a 2-tuple of number of enabled and total printers.
Definition at line 183 of file pretty_printers.py.
References gdb.command.pretty_printers.printer_enabled_p().
Referenced by gdb.command.pretty_printers.count_all_enabled_printers(), and gdb.command.pretty_printers.InfoPrettyPrinter.invoke().
gdb.command.pretty_printers.do_enable_pretty_printer | ( | arg, | |
flag ) |
Internal worker for enabling/disabling pretty-printers.
Definition at line 301 of file pretty_printers.py.
References gdb.current_progspace(), gdb.command.pretty_printers.do_enable_pretty_printer_1(), gdb.objfiles(), gdb.command.pretty_printers.parse_printer_regexps(), gdb.command.pretty_printers.pluralize(), and gdb.command.pretty_printers.show_pretty_printer_enabled_summary().
Referenced by gdb.command.pretty_printers.EnablePrettyPrinter.invoke(), and gdb.command.pretty_printers.DisablePrettyPrinter.invoke().
gdb.command.pretty_printers.do_enable_pretty_printer_1 | ( | pretty_printers, | |
name_re, | |||
subname_re, | |||
flag ) |
Worker for enabling/disabling pretty-printers. Arguments: pretty_printers: list of pretty-printers name_re: regular-expression object to select printers subname_re: regular expression object to select subprinters or None if all are affected flag: True for Enable, False for Disable Returns: The number of printers affected. This is just for informational purposes for the user.
Definition at line 238 of file pretty_printers.py.
References gdb.command.pretty_printers.printer_enabled_p().
Referenced by gdb.command.pretty_printers.do_enable_pretty_printer(), and gdb.command.pretty_printers.InfoPrettyPrinter.invoke().
gdb.command.pretty_printers.parse_printer_regexps | ( | arg | ) |
Internal utility to parse a pretty-printer command argv. Arguments: arg: The arguments to the command. The format is: [object-regexp [name-regexp]]. Individual printers in a collection are named as printer-name;subprinter-name. Returns: The result is a 3-tuple of compiled regular expressions, except that the resulting compiled subprinter regexp is None if not provided. Raises: SyntaxError: an error processing ARG
Definition at line 24 of file pretty_printers.py.
Referenced by gdb.command.pretty_printers.do_enable_pretty_printer(), and gdb.command.pretty_printers.InfoPrettyPrinter.invoke().
gdb.command.pretty_printers.pluralize | ( | text, | |
n, | |||
suffix = "s" ) |
Return TEXT pluralized if N != 1.
Definition at line 222 of file pretty_printers.py.
Referenced by gdb.command.pretty_printers.do_enable_pretty_printer(), and gdb.command.pretty_printers.InfoPrettyPrinter.invoke().
gdb.command.pretty_printers.printer_enabled_p | ( | printer | ) |
Internal utility to see if printer (or subprinter) is enabled.
Definition at line 76 of file pretty_printers.py.
Referenced by gdb.command.pretty_printers.count_enabled_printers(), gdb.command.pretty_printers.do_enable_pretty_printer_1(), gdb.command.pretty_printers.InfoPrettyPrinter.enabled_string(), and gdb.command.pretty_printers.InfoPrettyPrinter.invoke().
gdb.command.pretty_printers.register_pretty_printer_commands | ( | ) |
Call from a top level script to install the pretty-printer commands.
Definition at line 388 of file pretty_printers.py.
References gdb.command.pretty_printers.register_pretty_printer_commands().
Referenced by gdb.command.pretty_printers.DisablePrettyPrinter.invoke(), and gdb.command.pretty_printers.register_pretty_printer_commands().
gdb.command.pretty_printers.show_pretty_printer_enabled_summary | ( | ) |
Print the number of printers enabled/disabled. We count subprinters individually.
Definition at line 230 of file pretty_printers.py.
References gdb.command.pretty_printers.count_all_enabled_printers().
Referenced by gdb.command.pretty_printers.do_enable_pretty_printer(), and gdb.command.pretty_printers.InfoPrettyPrinter.invoke().