(update-copyright): Wrap final copyright-matching regexp in parens, so \1

gets all the year tokens, not just the last.  (The old regexp won with
the pre-POSIX defn of subexpressions with +.)
This commit is contained in:
Roland McGrath 1994-01-16 04:35:38 +00:00
parent 86e7b62748
commit a1d528953c

View file

@ -1,6 +1,6 @@
;;; upd-copyr.el --- update the copyright notice in a GNU Emacs Lisp file ;;; upd-copyr.el --- update the copyright notice in a GNU Emacs Lisp file
;;; Copyright (C) 1991, 1992, 1993 Free Software Foundation, Inc. ;;; Copyright (C) 1991, 1992, 1993, 1994 Free Software Foundation, Inc.
;; Author: Roland McGrath <roland@gnu.ai.mit.edu> ;; Author: Roland McGrath <roland@gnu.ai.mit.edu>
;; Keywords: maint ;; Keywords: maint
@ -74,7 +74,7 @@ than adding to it."
(search-forward "is free software" nil t) (search-forward "is free software" nil t)
(goto-char (point-min)))) (goto-char (point-min))))
(re-search-forward (re-search-forward
"[Cc]opyright[^0-9]*\\(\\([-, \t]*\\([0-9]+\\)\\)\\)+" "[Cc]opyright[^0-9]*\\(\\(\\([-, \t]*\\([0-9]+\\)\\)\\)+\\)"
nil t) nil t)
(or (not ask-upd) (or (not ask-upd)
(save-window-excursion (save-window-excursion