]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
lex.c (DIR_SEPARATOR): Define to be '/' if not already defined.
authorMumit Khan <khan@xraylith.wisc.edu>
Fri, 23 Jan 1998 18:35:06 +0000 (18:35 +0000)
committerJason Merrill <jason@gcc.gnu.org>
Fri, 23 Jan 1998 18:35:06 +0000 (13:35 -0500)
* lex.c (DIR_SEPARATOR): Define to be '/' if not already defined.
(file_name_nondirectory): Use.

From-SVN: r17461

gcc/cp/ChangeLog
gcc/cp/lex.c

index 5d5ccf9cfa0ca8f518afb87d457ba1deba1c915d..38b4afd361da829413a8afa3fb2167ce63fbef7d 100644 (file)
@@ -1,3 +1,8 @@
+Fri Jan 23 18:34:37 1998  Mumit Khan <khan@xraylith.wisc.edu>
+
+       * lex.c (DIR_SEPARATOR): Define to be '/' if not already defined.
+       (file_name_nondirectory): Use.
+
 Wed Jan 21 10:29:57 1998  Kriang Lerdsuwanakij  <lerdsuwa@scf.usc.edu>
 
        * pt.c (coerce_template_parms): Don't access elements of ARGLIST
index 1114a631e5c1acd8bf7512bb0fc9f1b2366b8550..a74e0fd259cd60371c28a10772c8fc1bdf1d13c2 100644 (file)
@@ -73,6 +73,10 @@ extern int errno;            /* needed for VAX.  */
 #define obstack_chunk_alloc xmalloc
 #define obstack_chunk_free free
 
+#ifndef DIR_SEPARATOR
+#define DIR_SEPARATOR '/'
+#endif
+
 extern struct obstack permanent_obstack;
 extern struct obstack *current_obstack, *saveable_obstack;
 
@@ -104,7 +108,7 @@ char *
 file_name_nondirectory (x)
      char *x;
 {
-  char *tmp = (char *) rindex (x, '/');
+  char *tmp = (char *) rindex (x, DIR_SEPARATOR);
   if (tmp)
     return (char *) (tmp + 1);
   else