summaryrefslogtreecommitdiff
path: root/gdb/gdb-demangle.h
Commit message (Collapse)AuthorAgeFilesLines
* Fix completer.c FIXME, and invalid pointer to pointer conversion.Pedro Alves2013-03-131-3/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | As mentioned in the previous patch, I grepped for "\*\*) &" and found one hit in completer.c. I was about to post a patch that simply made current_demangling_style_string const, and cast away constness at the xfree site. However, looking deeper, it seem to be there's a lot of dead code in the file. First, all external callers of set_demangling_style are found in the stabs reader, commented out for over 12 years: http://sourceware.org/ml/gdb-patches/2000-12/msg00214.html I don't think it's likely we'll ever make the older mangling schemes work for stabs. If we do, we can rediscuss the approach then. Then, set_demangling_command has special handling for unknown demangling styles, but "set demangle-style" is an enum command, and with those, the user can only specify a known enumeration value, by design: (gdb) set demangle-style gangnam-style Undefined item: "gangnam-style". This patch removes all that dead code, then makes current_demangling_style_string point to an element of demangling_style_names, as the FIXME suggests, and then makes current_demangling_style_string, removing the need for the 'const char **' cast. gdb/ 2013-03-13 Pedro Alves <palves@redhat.com> * dbxread.c (read_ofile_symtab, process_one_symbol): Remove commented out code. * demangle.c (current_demangling_style_string): Make it const. (set_demangling_command): Assert the demangling style is known. Remove all handling of unknown styles. Set 'current_demangling_style_string' to an element of the demangling_style_names array. (set_demangling_style): Delete. (_initialize_demangler): Set current_demangling_style_string to the element of the demangling_style_names array that corresponds to the default demangling style. Remove FIXME note. Don't call set_demangling_style. * gdb-demangle.h (set_demangling_style): Remove declaration.
* Consistent use of (C) after "Copyright".Pedro Alves2013-02-121-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | While writing the previous patch, I noticed that we're not consistent with the (C) in the copyright header. The maintainers manual prefers having it, though also says it's optional. We have over 10x more files with (C) than without in gdb's code, so I spent a few minutes grepping and fixing. Funny enough, the testsuite has it backwards. I'll leave that for another time. gdb/ 2013-02-12 Pedro Alves <palves@redhat.com> * amd64-darwin-tdep.c: Add (C) after Copyright. * cli/cli-cmds.h: Ditto. * cli/cli-decode.c: Ditto. * cli/cli-decode.h: Ditto. * cli/cli-dump.c: Ditto. * cli/cli-dump.h: Ditto. * cli/cli-interp.c: Ditto. * cli/cli-logging.c: Ditto. * cli/cli-script.c: Ditto. * cli/cli-script.h: Ditto. * cli/cli-setshow.c: Ditto. * cli/cli-setshow.h: Ditto. * cli/cli-utils.c: Ditto. * cli/cli-utils.h: Ditto. * config/alpha/nm-osf3.h: Ditto. * config/djgpp/djconfig.sh: Ditto. * config/i386/nm-fbsd.h: Ditto. * config/i386/nm-i386gnu.h: Ditto. * config/nm-linux.h: Ditto. * config/nm-nto.h: Ditto. * config/rs6000/nm-rs6000.h: Ditto. * config/sparc/nm-sol2.h: Ditto. * darwin-nat-info.c: Ditto. * dfp.c: Ditto. * dfp.h: Ditto. * gdb-demangle.h: Ditto. * i386-darwin-nat.c: Ditto. * i386-darwin-tdep.c: Ditto. * linux-fork.h: Ditto. * m32c-tdep.c: Ditto. * microblaze-linux-tdep.c: Ditto. * microblaze-rom.c: Ditto. * microblaze-tdep.c: Ditto. * microblaze-tdep.h: Ditto. * mips-linux-tdep.h: Ditto. * ppc-ravenscar-thread.c: Ditto. * ppc-ravenscar-thread.h: Ditto. * prologue-value.c: Ditto. * prologue-value.h: Ditto. * ravenscar-thread.c: Ditto. * ravenscar-thread.h: Ditto. * sparc-ravenscar-thread.c: Ditto. * sparc-ravenscar-thread.h: Ditto. * tilegx-linux-tdep.c: Ditto. * unwind_stop_reasons.def: Ditto. * windows-nat.h: Ditto. * xtensa-linux-tdep.c: Ditto. * xtensa-xtregs.c: Ditto. * regformats/regdat.sh: Ditto. * regformats/regdef.h: Ditto. gdb/gdbserver/ 2013-02-12 Pedro Alves <palves@redhat.com> * linux-xtensa-low.c: Ditto. * xtensa-xtregs.c: Ditto.
* Update years in copyright notice for the GDB files.Joel Brobecker2013-01-011-1/+1
| | | | | | | Two modifications: 1. The addition of 2013 to the copyright year range for every file; 2. The use of a single year range, instead of potentially multiple year ranges, as approved by the FSF.
* Copyright year update in most files of the GDB Project.Joel Brobecker2012-01-041-1/+1
| | | | | | gdb/ChangeLog: Copyright year update in most files of the GDB Project.
* * defs.h (is_cplus_marker, set_demangling_style): Moved to ...Doug Evans2011-11-101-0/+37
* 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".