]> git.eshelyaron.com Git - emacs.git/commitdiff
Fix header comment in generated bovine grammar file
authorGlenn Morris <rgm@gnu.org>
Wed, 28 Feb 2018 18:44:12 +0000 (13:44 -0500)
committerGlenn Morris <rgm@gnu.org>
Wed, 28 Feb 2018 18:44:12 +0000 (13:44 -0500)
* lisp/cedet/semantic/bovine/grammar.el (bovine--make-parser-1):
Fix header comment in generated scm-by.el.

lisp/cedet/semantic/bovine/grammar.el

index 0eab01b58b1ac62bad64b79b540f67fbe9085cdf..65c856a8cae371bfee228e2914243ab6d9eb8462 100644 (file)
@@ -475,6 +475,7 @@ Menu items are appended to the common grammar menu.")
         ;; This is with-demoted-errors.
         (condition-case err
             (with-current-buffer (find-file-noselect infile)
+              (setq infile buffer-file-name)
               (if outdir (setq default-directory outdir))
               (semantic-grammar-create-package nil t))
           (error (message "%s" (error-message-string err)) nil)))
@@ -509,8 +510,12 @@ Menu items are appended to the common grammar menu.")
 
 ;;; Commentary:
 ;;
-;; This file was generated from admin/grammars/"
-               lang ".by.
+;; This file was generated from "
+               (if (string-match "\\(OFFadmin/grammars/.*\\.by\\)\\'" infile)
+                   (match-string 1 infile)
+                 (concat "admin/grammars/"
+                         (if (string-equal lang "scm") "scheme" lang) ".by"))
+".
 
 ;;; Code:
 ")