]> code.delx.au - gnu-emacs/blobdiff - lisp/pcmpl-gnu.el
Add 2010 to copyright years.
[gnu-emacs] / lisp / pcmpl-gnu.el
index b413ca992311e2f12a54e0c0f4bed3363b178d0f..accab1dea9d9ef6670f29586880af33f93e48c31 100644 (file)
@@ -1,14 +1,14 @@
 ;;; pcmpl-gnu.el --- completions for GNU project tools
 
 ;; Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004,
-;;   2005, 2006, 2007 Free Software Foundation, Inc.
+;;   2005, 2006, 2007, 2008, 2009, 2010 Free Software Foundation, Inc.
 
 ;; This file is part of GNU Emacs.
 
-;; GNU Emacs is free software; you can redistribute it and/or modify
+;; GNU Emacs is free software: you can redistribute it and/or modify
 ;; it under the terms of the GNU General Public License as published by
-;; the Free Software Foundation; either version 2, or (at your option)
-;; any later version.
+;; the Free Software Foundation, either version 3 of the License, or
+;; (at your option) any later version.
 
 ;; GNU Emacs is distributed in the hope that it will be useful,
 ;; but WITHOUT ANY WARRANTY; without even the implied warranty of
@@ -16,9 +16,7 @@
 ;; GNU General Public License for more details.
 
 ;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING.  If not, write to the
-;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
-;; Boston, MA 02110-1301, USA.
+;; along with GNU Emacs.  If not, see <http://www.gnu.org/licenses/>.
 
 ;;; Commentary:
 
@@ -37,7 +35,7 @@
 
 (defcustom pcmpl-gnu-makefile-regexps
   '("\\`GNUmakefile" "\\`Makefile" "\\.mak\\'")
-  "*A list of regexps that will match Makefile names."
+  "A list of regexps that will match Makefile names."
   :type '(repeat regexp)
   :group 'pcmpl-gnu)
 
 
 (defun pcmpl-gnu-makefile-names ()
   "Return a list of possible makefile names."
-  (let ((names (list t))
-       (reg pcmpl-gnu-makefile-regexps))
-    (while reg
-      (nconc names (pcomplete-entries (car reg)))
-      (setq reg (cdr reg)))
-    (cdr names)))
+  (pcomplete-entries (mapconcat 'identity pcmpl-gnu-makefile-regexps "\\|")))
 
 (defun pcmpl-gnu-make-rule-names ()
   "Return a list of possible make rule names in MAKEFILE."
 
 (defcustom pcmpl-gnu-tarfile-regexp
   "\\.t\\(ar\\(\\.\\(gz\\|bz2\\|Z\\)\\)?\\|gz\\|a[zZ]\\|z2\\)\\'"
-  "*A regexp which matches any tar archive."
+  "A regexp which matches any tar archive."
   :type 'regexp
   :group 'pcmpl-gnu)
 
 (defvar pcmpl-gnu-tar-buffer nil)
 
+;; Only used in tar-mode buffers.
+(defvar tar-parse-info)
+(declare-function tar-header-name "tar-mode" t t)
+
 ;;;###autoload
 (defun pcomplete/tar ()
   "Completion for the GNU tar utility."
 ;;;###autoload
 (defalias 'pcomplete/gdb 'pcomplete/xargs)
 
-;;; arch-tag: 06d2b429-dcb1-4a57-84e1-f70d87781183
+;; arch-tag: 06d2b429-dcb1-4a57-84e1-f70d87781183
 ;;; pcmpl-gnu.el ends here