aboutsummaryrefslogtreecommitdiff
path: root/gdb/utils.c
diff options
context:
space:
mode:
authorDoug Evans <dje@google.com>2011-11-10 20:21:29 +0000
committerDoug Evans <dje@google.com>2011-11-10 20:21:29 +0000
commit50f182aa6671dea0fdcf063d5974c623332f3e63 (patch)
tree305e9bf4cddbeadeaa410ab4ad250ded684a83b8 /gdb/utils.c
parent6953d2240a9e4d4f5d6b8369c2367377b7d2ef47 (diff)
downloadgdb-50f182aa6671dea0fdcf063d5974c623332f3e63.zip
gdb-50f182aa6671dea0fdcf063d5974c623332f3e63.tar.gz
gdb-50f182aa6671dea0fdcf063d5974c623332f3e63.tar.bz2
* defs.h (is_cplus_marker, set_demangling_style): Moved to ...
* gdb-demangle.h: ... here. New file. * demangle.c: #include "gdb-demangle.h". (_initialize_demangler): Use initialize_file_ftype for prototype. Move "set demangle" and "set asm-demangle" parameters here from utils.c (demangle, show_demangle, asm_demangle, show_asm_demangle): Move here from utils.c * utils.c: Update. #include "gdb-demangle.h". * symtab.h (asm_demangle): Delete. (demangle): Move declaration next to use. * breakpoint.c: #include "gdb-demangle.h" instead of "demangle.h". * dwarf2read.c: #include "gdb-demangle.h". * gnu-v2-abi.c: Ditto. * jv-typeprint.c: Ditto. * mdebugread.c: Ditto. * p-typeprint.c: Ditto. * stabsread.c: Ditto. * printcmd.c: Ditto. (asm_demangle): Delete declaration. * tui/tui-stack.c: #include "gdb-demangle.h".
Diffstat (limited to 'gdb/utils.c')
-rw-r--r--gdb/utils.c45
1 files changed, 1 insertions, 44 deletions
diff --git a/gdb/utils.c b/gdb/utils.c
index 008baac..82a0f45 100644
--- a/gdb/utils.c
+++ b/gdb/utils.c
@@ -50,7 +50,7 @@
#include "serial.h"
#include "bfd.h"
#include "target.h"
-#include "demangle.h"
+#include "gdb-demangle.h"
#include "expression.h"
#include "language.h"
#include "charset.h"
@@ -138,35 +138,6 @@ int quit_flag;
int immediate_quit;
-/* Nonzero means that encoded C++/ObjC names should be printed out in their
- C++/ObjC form rather than raw. */
-
-int demangle = 1;
-static void
-show_demangle (struct ui_file *file, int from_tty,
- struct cmd_list_element *c, const char *value)
-{
- fprintf_filtered (file,
- _("Demangling of encoded C++/ObjC names "
- "when displaying symbols is %s.\n"),
- value);
-}
-
-/* Nonzero means that encoded C++/ObjC names should be printed out in their
- C++/ObjC form even in assembler language displays. If this is set, but
- DEMANGLE is zero, names are printed raw, i.e. DEMANGLE controls. */
-
-int asm_demangle = 0;
-static void
-show_asm_demangle (struct ui_file *file, int from_tty,
- struct cmd_list_element *c, const char *value)
-{
- fprintf_filtered (file,
- _("Demangling of C++/ObjC names in "
- "disassembly listings is %s.\n"),
- value);
-}
-
/* Nonzero means that strings with character values >0x7F should be printed
as octal escapes. Zero means just print the value (e.g. it's an
international character, and the terminal or window can cope.) */
@@ -2864,13 +2835,6 @@ Show number of lines gdb thinks are in a page."), NULL,
init_page_info ();
- add_setshow_boolean_cmd ("demangle", class_support, &demangle, _("\
-Set demangling of encoded C++/ObjC names when displaying symbols."), _("\
-Show demangling of encoded C++/ObjC names when displaying symbols."), NULL,
- NULL,
- show_demangle,
- &setprintlist, &showprintlist);
-
add_setshow_boolean_cmd ("pagination", class_support,
&pagination_enabled, _("\
Set state of pagination."), _("\
@@ -2895,13 +2859,6 @@ Show printing of 8-bit characters in strings as \\nnn."), NULL,
show_sevenbit_strings,
&setprintlist, &showprintlist);
- add_setshow_boolean_cmd ("asm-demangle", class_support, &asm_demangle, _("\
-Set demangling of C++/ObjC names in disassembly listings."), _("\
-Show demangling of C++/ObjC names in disassembly listings."), NULL,
- NULL,
- show_asm_demangle,
- &setprintlist, &showprintlist);
-
add_setshow_boolean_cmd ("timestamp", class_maintenance,
&debug_timestamp, _("\
Set timestamping of debugging messages."), _("\