This is the mail archive of the gdb-patches@sources.redhat.com mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[patch] useless code in symtab.c


In my eternal quest to understand symtab.c, I found an unnecessary
declaration and a function that is never called; here's a patch to
delete them.  I have no idea what was up with the
find_template_name_end declaration, but nobody in symtab.c calls it
any more; and cplusplus_hint's functionality has been moved into
cplusplus_error.

No new regressions.  This patch seems obvious; I'll commit it in a
couple of days unless somebody complains.

David Carlton
carlton@math.stanford.edu

2002-10-23  David Carlton  <carlton@math.stanford.edu>

	* symtab.c: Delete cplusplus_hint.
	Delete prototype for find_template_name_end.

Index: symtab.c
===================================================================
RCS file: /cvs/src/src/gdb/symtab.c,v
retrieving revision 1.70
diff -u -p -r1.70 symtab.c
--- symtab.c	20 Sep 2002 14:58:58 -0000	1.70
+++ symtab.c	23 Oct 2002 21:04:54 -0000
@@ -50,11 +50,6 @@
 #include <ctype.h>
 #include "cp-abi.h"
 
-/* Prototype for one function in parser-defs.h,
-   instead of including that entire file. */
-
-extern char *find_template_name_end (char *);
-
 /* Prototypes for local functions */
 
 static void completion_list_add_name (char *, char *, int, char *, char *);
@@ -120,19 +115,6 @@ struct type *builtin_type_error;
    value_of_this. */
 
 const struct block *block_found;
-
-/* While the C++ support is still in flux, issue a possibly helpful hint on
-   using the new command completion feature on single quoted demangled C++
-   symbols.  Remove when loose ends are cleaned up.   FIXME -fnf */
-
-static void
-cplusplus_hint (char *name)
-{
-  while (*name == '\'')
-    name++;
-  printf_filtered ("Hint: try '%s<TAB> or '%s<ESC-?>\n", name, name);
-  printf_filtered ("(Note leading single quote.)\n");
-}
 
 /* Check for a symtab of a specific name; first in symtabs, then in
    psymtabs.  *If* there is no '/' in the name, a match after a '/'


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]