toplev.c (file_name_nondirectory): Remove.
authorNeil Booth <neil@daikokuya.demon.co.uk>
Sat, 10 Mar 2001 16:33:57 +0000 (16:33 +0000)
committerNeil Booth <neil@gcc.gnu.org>
Sat, 10 Mar 2001 16:33:57 +0000 (16:33 +0000)
* toplev.c (file_name_nondirectory): Remove.
* toplev.h: Similarly.
* dwarf2out.c (compute_section_prefix): Use lbasename instead
of file_name_nondirectory.
* cp/lex.c: Delete duplicate pending_lang_change.
* cp/lex.c (handle_pragma_interface, handle_pragma_implementation):
Similarly.
* cp/repo.c (get_base_filename, open_repo_file): Similarly.
* cp/cp-tree.h: Remove file_name_nondirectory prototype.

From-SVN: r40369

gcc/ChangeLog
gcc/cp/ChangeLog
gcc/cp/cp-tree.h
gcc/cp/lex.c
gcc/cp/repo.c
gcc/dwarf2out.c
gcc/toplev.c
gcc/toplev.h

index 076ad3476d63425a06d63b73ef179c67da21e48a..0d49ab4d1c46688409b4960ccbf987be7613b5e1 100644 (file)
@@ -1,3 +1,10 @@
+2001-03-10  Neil Booth  <neil@daikokuya.demon.co.uk>
+
+       * toplev.c (file_name_nondirectory): Remove.
+       * toplev.h: Similarly.
+       * dwarf2out.c (compute_section_prefix): Use lbasename instead
+       of file_name_nondirectory.
+
 Sat Mar 10 10:36:45 2001  Richard Kenner  <kenner@vlsi1.ultra.nyu.edu>
 
        * mips-tdump.c (read_seek): Call xmalloc, not malloc.
index 4b581969a180382b5041f0b847090f85a5214fd8..3f0fa1926073ad6de7e63eff858eb9a41232311a 100644 (file)
@@ -1,3 +1,14 @@
+2001-03-10  Neil Booth  <neil@daikokuya.demon.co.uk>
+
+       * cp/lex.c: Delete duplicate pending_lang_change.
+
+2001-03-10  Neil Booth  <neil@daikokuya.demon.co.uk>
+
+       * cp/lex.c (handle_pragma_interface, handle_pragma_implementation):
+       Similarly.
+       * cp/repo.c (get_base_filename, open_repo_file): Similarly.
+       * cp/cp-tree.h: Remove file_name_nondirectory prototype.
+
 2001-03-09  Zack Weinberg  <zackw@stanford.edu>
 
        * Make-lang.in: Add dependencies on $(TM_P_H) as appropriate.
index a7da5d8b24c5d17abb40e35d1d4946a860f51250..d948364c248de88c313fba31d647801cadc8f678 100644 (file)
@@ -4051,7 +4051,6 @@ extern tree build_java_class_ref                PARAMS ((tree));
 /* in input.c */
 
 /* in lex.c */
-extern char *file_name_nondirectory            PARAMS ((const char *));
 extern tree make_pointer_declarator            PARAMS ((tree, tree));
 extern tree make_reference_declarator          PARAMS ((tree, tree));
 extern tree make_call_declarator               PARAMS ((tree, tree, tree, tree));
index f493928faaf75c85ed04ed8402077c97ec4f405d..690e66a38dadb991dfe0a10cd870c5418076383c 100644 (file)
@@ -84,10 +84,6 @@ static void init_operators PARAMS ((void));
 
 #include "cpplib.h"
 
-/* Pending language change.
-   Positive is push count, negative is pop count.  */
-int pending_lang_change = 0;
-
 extern int yychar;             /*  the lookahead symbol                */
 extern YYSTYPE yylval;         /*  the semantic value of the           */
                                /*  lookahead symbol                    */
@@ -1109,7 +1105,7 @@ handle_pragma_interface (dfile)
   if (fname == (tree)-1)
     return;
   else if (fname == 0)
-    main_filename = file_name_nondirectory (input_filename);
+    main_filename = lbasename (input_filename);
   else
     main_filename = TREE_STRING_POINTER (fname);
 
@@ -1158,7 +1154,7 @@ handle_pragma_implementation (dfile)
        main_filename = main_input_filename;
       else
        main_filename = input_filename;
-      main_filename = file_name_nondirectory (main_filename);
+      main_filename = lbasename (main_filename);
     }
   else
     {
index e86e1f0805b77cbcc8d04181945f22cced233ab6..897648a0b2849cfc691407de9f634d19f6ca1077 100644 (file)
@@ -268,7 +268,7 @@ get_base_filename (filename)
       return NULL;
     }
 
-  return file_name_nondirectory (filename);
+  return lbasename (filename);
 }        
 
 static void
@@ -281,7 +281,7 @@ open_repo_file (filename)
   if (s == NULL)
     return;
 
-  p = file_name_nondirectory (s);
+  p = lbasename (s);
   p = strrchr (p, '.');
   if (! p)
     p = s + strlen (s);
index adf0204abf2a9979e9019677c68d63b89fde4b67..573bc913c94512bbd148285ebd1ad107d9458e8f 100644 (file)
@@ -4972,7 +4972,7 @@ compute_section_prefix (unit_die)
   die_checksum (unit_die, &ctx);
   md5_finish_ctx (&ctx, checksum);
 
-  p = file_name_nondirectory (get_AT_string (unit_die, DW_AT_name));
+  p = lbasename (get_AT_string (unit_die, DW_AT_name));
   name = (char *) alloca (strlen (p) + 64);
   sprintf (name, "%s.", p);
 
index 6bddc9c3690013feda83e2bd774f1bbcdbebe908..cfe797e0554b0d502b85294212806e3eef46a514 100644 (file)
@@ -1733,21 +1733,6 @@ strip_off_ending (name, len)
     }
 }
 
-/* Given a file name X, return the nondirectory portion.  */
-
-char *
-file_name_nondirectory (x)
-     const char *x;
-{
-  char *tmp = (char *) strrchr (x, '/');
-  if (DIR_SEPARATOR != '/' && ! tmp)
-    tmp = (char *) strrchr (x, DIR_SEPARATOR);
-  if (tmp)
-    return (char *) (tmp + 1);
-  else
-    return (char *) x;
-}
-
 /* Output a quoted string.  */
 
 void
index 0e9e10bdad4af61111f1ed929c2f693349c32cc3..6880e9fcc76004ba4b404f9710a8d85d80e691b8 100644 (file)
@@ -36,7 +36,6 @@ extern int read_integral_parameter    PARAMS ((const char *, const char *,
                                                const int));
 extern int count_error                 PARAMS ((int));
 extern void strip_off_ending           PARAMS ((char *, int));
-extern char *file_name_nondirectory    PARAMS ((const char *));
 extern void print_time                 PARAMS ((const char *, long));
 extern void debug_start_source_file    PARAMS ((const char *));
 extern void debug_end_source_file      PARAMS ((unsigned));