aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorMumit Khan <khan@xraylith.wisc.edu>1998-01-23 18:35:06 +0000
committerJason Merrill <jason@gcc.gnu.org>1998-01-23 13:35:06 -0500
commitab535daca9214d040042550cd2f565dfa3497423 (patch)
tree29bdaac36ea03ac1211e0bf2a16cdf478efd1a1d /gcc
parentd1fefbce9d3fdaff1b5d9db74690fbe221752c18 (diff)
downloadgcc-ab535daca9214d040042550cd2f565dfa3497423.zip
gcc-ab535daca9214d040042550cd2f565dfa3497423.tar.gz
gcc-ab535daca9214d040042550cd2f565dfa3497423.tar.bz2
lex.c (DIR_SEPARATOR): Define to be '/' if not already defined.
* lex.c (DIR_SEPARATOR): Define to be '/' if not already defined. (file_name_nondirectory): Use. From-SVN: r17461
Diffstat (limited to 'gcc')
-rw-r--r--gcc/cp/ChangeLog5
-rw-r--r--gcc/cp/lex.c6
2 files changed, 10 insertions, 1 deletions
diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog
index 5d5ccf9..38b4afd 100644
--- a/gcc/cp/ChangeLog
+++ b/gcc/cp/ChangeLog
@@ -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
diff --git a/gcc/cp/lex.c b/gcc/cp/lex.c
index 1114a63..a74e0fd 100644
--- a/gcc/cp/lex.c
+++ b/gcc/cp/lex.c
@@ -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