manpagez: man pages & more
info gdb
Home | html | info | man
[ < ] [ > ]   [ << ] [ Up ] [ >> ]         [Top] [Contents] [Index] [ ? ]

12.4.1.7 No value for GDBN Features for C++

Some No value for GDBN commands are particularly useful with C++, and some are designed specifically for use with C++. Here is a summary:

breakpoint menus

When you want a breakpoint in a function whose name is overloaded, No value for GDBN breakpoint menus help you specify which function definition you want. See section Breakpoint Menus.

rbreak regex

Setting breakpoints using regular expressions is helpful for setting breakpoints on overloaded functions that are not members of any special classes. See section Setting Breakpoints.

catch throw
catch catch

Debug C++ exception handling using these commands. See section Setting Catchpoints.

ptype typename

Print inheritance relationships as well as other information for type typename. See section Examining the Symbol Table.

set print demangle
show print demangle
set print asm-demangle
show print asm-demangle

Control whether C++ symbols display in their source form, both when displaying code as C++ source and when displaying disassemblies. See section Print Settings.

set print object
show print object

Choose whether to print derived (actual) or declared types of objects. See section Print Settings.

set print vtbl
show print vtbl

Control the format for printing virtual function tables. See section Print Settings. (The vtbl commands do not work on programs compiled with the HP ANSI C++ compiler (aCC).)

set overload-resolution on

Enable overload resolution for C++ expression evaluation. The default is on. For overloaded functions, No value for GDBN evaluates the arguments and searches for a function whose signature matches the argument types, using the standard C++ conversion rules (see C++ Expressions, for details). If it cannot find a match, it emits a message.

set overload-resolution off

Disable overload resolution for C++ expression evaluation. For overloaded functions that are not class member functions, No value for GDBN chooses the first function of the specified name that it finds in the symbol table, whether or not its arguments are of the correct type. For overloaded functions that are class member functions, No value for GDBN searches for a function whose signature exactly matches the argument types.

show overload-resolution

Show the current setting of overload resolution.

Overloaded symbol names

You can specify a particular definition of an overloaded symbol, using the same notation that is used to declare such symbols in C++: type symbol(types) rather than just symbol. You can also use the No value for GDBN command-line word completion facilities to list the available choices, or to finish the type list for you. See section Command Completion, for details on how to do this.


[ < ] [ > ]   [ << ] [ Up ] [ >> ]         [Top] [Contents] [Index] [ ? ]
© manpagez.com 2000-2017
Individual documents may contain additional copyright information.