]> git.saurik.com Git - bison.git/blobdiff - src/files.c
* src/scan-gram.l (<SC_ESCAPED_CHARACTER>): Convert to unsigned
[bison.git] / src / files.c
index 1e084f6ec253ed7ed61c5ac7eefe1d42d798cfea..1252aab0dc1e574636ceea5bf38b51f862b82027 100644 (file)
@@ -1,5 +1,5 @@
 /* Open and close files for bison,
 /* Open and close files for bison,
-   Copyright 1984, 1986, 1989, 1992, 2000, 2001, 2002
+   Copyright (C) 1984, 1986, 1989, 1992, 2000, 2001, 2002
    Free Software Foundation, Inc.
 
    This file is part of Bison, the GNU Compiler Compiler.
    Free Software Foundation, Inc.
 
    This file is part of Bison, the GNU Compiler Compiler.
@@ -32,8 +32,6 @@ const char *base_name PARAMS ((char const *name));
 
 FILE *finput = NULL;
 
 
 FILE *finput = NULL;
 
-struct obstack action_obstack;
-struct obstack output_obstack;
 struct obstack pre_prologue_obstack;
 struct obstack post_prologue_obstack;
 
 struct obstack pre_prologue_obstack;
 struct obstack post_prologue_obstack;
 
@@ -386,11 +384,11 @@ compute_base_names (void)
       else
        {
          /* Otherwise, the short base name is computed from the input
       else
        {
          /* Otherwise, the short base name is computed from the input
-            grammar: `foo.yy' => `foo'.  */
+            grammar: `foo/bar.yy' => `bar'.  */
          filename_split (infile, &base, &tab, &ext);
          short_base_name =
          filename_split (infile, &base, &tab, &ext);
          short_base_name =
-           xstrndup (infile,
-                     (strlen (infile) - (ext ? strlen (ext) : 0)));
+           xstrndup (base,
+                     (strlen (base) - (ext ? strlen (ext) : 0)));
        }
 
       /* In these cases, always append `.tab'. */
        }
 
       /* In these cases, always append `.tab'. */