aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorStefan Monnier2019-10-03 10:36:00 -0400
committerStefan Monnier2019-10-03 10:36:00 -0400
commit44dfa7a834c11897fd64dba7b15cb0dcce0af980 (patch)
tree2e4f011ca1f8a04dbd7d3688a0c8e7594a41ef23
parentc164f749794e7252887cce10cbfa31fd012351c3 (diff)
downloademacs-44dfa7a834c11897fd64dba7b15cb0dcce0af980.tar.gz
emacs-44dfa7a834c11897fd64dba7b15cb0dcce0af980.zip
* lisp/pcomplete.el: Mark 'pcomplete' command as obsolete
Remove redundant ':group's. (pcomplete, pcomplete-help): Mark as obsolete.
-rw-r--r--etc/NEWS5
-rw-r--r--lisp/eshell/em-cmpl.el2
-rw-r--r--lisp/pcomplete.el112
3 files changed, 56 insertions, 63 deletions
diff --git a/etc/NEWS b/etc/NEWS
index 00a01999a73..c8cc7537b04 100644
--- a/etc/NEWS
+++ b/etc/NEWS
@@ -1532,6 +1532,11 @@ available for output of asynchronous shell commands.
1532 1532
1533** Pcomplete 1533** Pcomplete
1534 1534
1535*** The 'pcomplete' command is now obsolete
1536The Pcomplete functionality can be obtained via completion-at-point
1537instead, by adding pcomplete-completions-at-point to
1538completion-at-point-functions.
1539
1535*** The function 'pcomplete-uniquify-list' has been renamed from 1540*** The function 'pcomplete-uniquify-list' has been renamed from
1536'pcomplete-uniqify-list'. 1541'pcomplete-uniqify-list'.
1537 1542
diff --git a/lisp/eshell/em-cmpl.el b/lisp/eshell/em-cmpl.el
index 7f203142589..d0e52f9651e 100644
--- a/lisp/eshell/em-cmpl.el
+++ b/lisp/eshell/em-cmpl.el
@@ -409,7 +409,7 @@ to writing a completion function."
409 (let ((filename (pcomplete-arg)) glob-name) 409 (let ((filename (pcomplete-arg)) glob-name)
410 (if (file-name-directory filename) 410 (if (file-name-directory filename)
411 (if eshell-force-execution 411 (if eshell-force-execution
412 (pcomplete-dirs-or-entries nil 'file-readable-p) 412 (pcomplete-dirs-or-entries nil #'file-readable-p)
413 (pcomplete-executables)) 413 (pcomplete-executables))
414 (if (and (> (length filename) 0) 414 (if (and (> (length filename) 0)
415 (eq (aref filename 0) eshell-explicit-command-char)) 415 (eq (aref filename 0) eshell-explicit-command-char))
diff --git a/lisp/pcomplete.el b/lisp/pcomplete.el
index 401e5aa1da5..281f2924274 100644
--- a/lisp/pcomplete.el
+++ b/lisp/pcomplete.el
@@ -30,7 +30,7 @@
30;; To use pcomplete with shell-mode, for example, you will need the 30;; To use pcomplete with shell-mode, for example, you will need the
31;; following in your init file: 31;; following in your init file:
32;; 32;;
33;; (add-hook 'shell-mode-hook 'pcomplete-shell-setup) 33;; (add-hook 'shell-mode-hook #'pcomplete-shell-setup)
34;; 34;;
35;; Most of the code below simply provides support mechanisms for 35;; Most of the code below simply provides support mechanisms for
36;; writing completion functions. Completion functions themselves are 36;; writing completion functions. Completion functions themselves are
@@ -105,7 +105,7 @@
105;; 105;;
106;; (defun pcomplete/example () 106;; (defun pcomplete/example ()
107;; (pcomplete-here (pcomplete-entries)) 107;; (pcomplete-here (pcomplete-entries))
108;; (if (pcomplete-test 'file-directory-p) 108;; (if (pcomplete-test #'file-directory-p)
109;; (pcomplete-here (pcomplete-dirs)) 109;; (pcomplete-here (pcomplete-dirs))
110;; (pcomplete-here (pcomplete-entries)))) 110;; (pcomplete-here (pcomplete-entries))))
111;; 111;;
@@ -129,31 +129,26 @@
129 129
130(defcustom pcomplete-file-ignore nil 130(defcustom pcomplete-file-ignore nil
131 "A regexp of filenames to be disregarded during file completion." 131 "A regexp of filenames to be disregarded during file completion."
132 :type '(choice regexp (const :tag "None" nil)) 132 :type '(choice regexp (const :tag "None" nil)))
133 :group 'pcomplete)
134 133
135(defcustom pcomplete-dir-ignore nil 134(defcustom pcomplete-dir-ignore nil
136 "A regexp of names to be disregarded during directory completion." 135 "A regexp of names to be disregarded during directory completion."
137 :type '(choice regexp (const :tag "None" nil)) 136 :type '(choice regexp (const :tag "None" nil)))
138 :group 'pcomplete)
139 137
140(defcustom pcomplete-ignore-case (memq system-type '(ms-dos windows-nt cygwin)) 138(defcustom pcomplete-ignore-case (memq system-type '(ms-dos windows-nt cygwin))
141 ;; FIXME: the doc mentions file-name completion, but the code 139 ;; FIXME: the doc mentions file-name completion, but the code
142 ;; seems to apply it to all completions. 140 ;; seems to apply it to all completions.
143 "If non-nil, ignore case when doing filename completion." 141 "If non-nil, ignore case when doing filename completion."
144 :type 'boolean 142 :type 'boolean)
145 :group 'pcomplete)
146 143
147(defcustom pcomplete-autolist nil 144(defcustom pcomplete-autolist nil
148 "If non-nil, automatically list possibilities on partial completion. 145 "If non-nil, automatically list possibilities on partial completion.
149This mirrors the optional behavior of tcsh." 146This mirrors the optional behavior of tcsh."
150 :type 'boolean 147 :type 'boolean)
151 :group 'pcomplete)
152 148
153(defcustom pcomplete-suffix-list (list ?/ ?:) 149(defcustom pcomplete-suffix-list (list ?/ ?:)
154 "A list of characters which constitute a proper suffix." 150 "A list of characters which constitute a proper suffix."
155 :type '(repeat character) 151 :type '(repeat character))
156 :group 'pcomplete)
157(make-obsolete-variable 'pcomplete-suffix-list nil "24.1") 152(make-obsolete-variable 'pcomplete-suffix-list nil "24.1")
158 153
159(defcustom pcomplete-recexact nil 154(defcustom pcomplete-recexact nil
@@ -161,25 +156,22 @@ This mirrors the optional behavior of tcsh."
161This mirrors the optional behavior of tcsh. 156This mirrors the optional behavior of tcsh.
162 157
163A non-nil value is useful if `pcomplete-autolist' is non-nil too." 158A non-nil value is useful if `pcomplete-autolist' is non-nil too."
164 :type 'boolean 159 :type 'boolean)
165 :group 'pcomplete)
166 160
167(define-obsolete-variable-alias 161(define-obsolete-variable-alias
168 'pcomplete-arg-quote-list 'comint-file-name-quote-list "24.3") 162 'pcomplete-arg-quote-list 'comint-file-name-quote-list "24.3")
169 163
170(defcustom pcomplete-man-function 'man 164(defcustom pcomplete-man-function #'man
171 "A function to that will be called to display a manual page. 165 "A function to that will be called to display a manual page.
172It will be passed the name of the command to document." 166It will be passed the name of the command to document."
173 :type 'function 167 :type 'function)
174 :group 'pcomplete)
175 168
176(defcustom pcomplete-compare-entry-function 'string-lessp 169(defcustom pcomplete-compare-entry-function #'string-lessp
177 "This function is used to order file entries for completion. 170 "This function is used to order file entries for completion.
178The behavior of most all shells is to sort alphabetically." 171The behavior of most all shells is to sort alphabetically."
179 :type '(radio (function-item string-lessp) 172 :type '(radio (function-item string-lessp)
180 (function-item file-newer-than-file-p) 173 (function-item file-newer-than-file-p)
181 (function :tag "Other")) 174 (function :tag "Other")))
182 :group 'pcomplete)
183 175
184(defcustom pcomplete-help nil 176(defcustom pcomplete-help nil
185 "A string or function (or nil) used for context-sensitive help. 177 "A string or function (or nil) used for context-sensitive help.
@@ -188,8 +180,7 @@ If non-nil, it must a sexp that will be evaluated, and whose
188result will be shown in the minibuffer. 180result will be shown in the minibuffer.
189If nil, the function `pcomplete-man-function' will be called with the 181If nil, the function `pcomplete-man-function' will be called with the
190current command argument." 182current command argument."
191 :type '(choice string sexp (const :tag "Use man page" nil)) 183 :type '(choice string sexp (const :tag "Use man page" nil)))
192 :group 'pcomplete)
193 184
194(defcustom pcomplete-expand-before-complete nil 185(defcustom pcomplete-expand-before-complete nil
195 "If non-nil, expand the current argument before completing it. 186 "If non-nil, expand the current argument before completing it.
@@ -199,11 +190,10 @@ resolved first, and the resultant value that will be completed against
199to be inserted in the buffer. Note that exactly what gets expanded 190to be inserted in the buffer. Note that exactly what gets expanded
200and how is entirely up to the behavior of the 191and how is entirely up to the behavior of the
201`pcomplete-parse-arguments-function'." 192`pcomplete-parse-arguments-function'."
202 :type 'boolean 193 :type 'boolean)
203 :group 'pcomplete)
204 194
205(defcustom pcomplete-parse-arguments-function 195(defcustom pcomplete-parse-arguments-function
206 'pcomplete-parse-buffer-arguments 196 #'pcomplete-parse-buffer-arguments
207 "A function to call to parse the current line's arguments. 197 "A function to call to parse the current line's arguments.
208It should be called with no parameters, and with point at the position 198It should be called with no parameters, and with point at the position
209of the argument that is to be completed. 199of the argument that is to be completed.
@@ -218,8 +208,7 @@ representation of that argument), and BEG-POS gives the beginning
218position of each argument, as it is seen by the user. The establishes 208position of each argument, as it is seen by the user. The establishes
219a relationship between the fully resolved value of the argument, and 209a relationship between the fully resolved value of the argument, and
220the textual representation of the argument." 210the textual representation of the argument."
221 :type 'function 211 :type 'function)
222 :group 'pcomplete)
223 212
224(defcustom pcomplete-cycle-completions t 213(defcustom pcomplete-cycle-completions t
225 "If non-nil, hitting the TAB key cycles through the completion list. 214 "If non-nil, hitting the TAB key cycles through the completion list.
@@ -230,8 +219,7 @@ it acts more like zsh or 4nt, showing the first maximal match first,
230followed by any further matches on each subsequent pressing of the TAB 219followed by any further matches on each subsequent pressing of the TAB
231key. \\[pcomplete-list] is the key to press if the user wants to see 220key. \\[pcomplete-list] is the key to press if the user wants to see
232the list of possible completions." 221the list of possible completions."
233 :type 'boolean 222 :type 'boolean)
234 :group 'pcomplete)
235 223
236(defcustom pcomplete-cycle-cutoff-length 5 224(defcustom pcomplete-cycle-cutoff-length 5
237 "If the number of completions is greater than this, don't cycle. 225 "If the number of completions is greater than this, don't cycle.
@@ -246,8 +234,7 @@ has already entered enough input to disambiguate most of the
246possibilities, and therefore they are probably most interested in 234possibilities, and therefore they are probably most interested in
247cycling through the candidates. Set this value to nil if you want 235cycling through the candidates. Set this value to nil if you want
248cycling to always be enabled." 236cycling to always be enabled."
249 :type '(choice integer (const :tag "Always cycle" nil)) 237 :type '(choice integer (const :tag "Always cycle" nil)))
250 :group 'pcomplete)
251 238
252(defcustom pcomplete-restore-window-delay 1 239(defcustom pcomplete-restore-window-delay 1
253 "The number of seconds to wait before restoring completion windows. 240 "The number of seconds to wait before restoring completion windows.
@@ -258,19 +245,17 @@ displayed will be restored), after this many seconds of idle time. If
258set to nil, completion windows will be left on second until the user 245set to nil, completion windows will be left on second until the user
259removes them manually. If set to 0, they will disappear immediately 246removes them manually. If set to 0, they will disappear immediately
260after the user enters a key other than TAB." 247after the user enters a key other than TAB."
261 :type '(choice integer (const :tag "Never restore" nil)) 248 :type '(choice integer (const :tag "Never restore" nil)))
262 :group 'pcomplete)
263 249
264(defcustom pcomplete-try-first-hook nil 250(defcustom pcomplete-try-first-hook nil
265 "A list of functions which are called before completing an argument. 251 "A list of functions which are called before completing an argument.
266This can be used, for example, for completing things which might apply 252This can be used, for example, for completing things which might apply
267to all arguments, such as variable names after a $." 253to all arguments, such as variable names after a $."
268 :type 'hook 254 :type 'hook)
269 :group 'pcomplete)
270 255
271(defsubst pcomplete-executables (&optional regexp) 256(defsubst pcomplete-executables (&optional regexp)
272 "Complete amongst a list of directories and executables." 257 "Complete amongst a list of directories and executables."
273 (pcomplete-entries regexp 'file-executable-p)) 258 (pcomplete-entries regexp #'file-executable-p))
274 259
275(defmacro pcomplete-here (&optional form stub paring form-only) 260(defmacro pcomplete-here (&optional form stub paring form-only)
276 "Complete against the current argument, if at the end. 261 "Complete against the current argument, if at the end.
@@ -310,13 +295,11 @@ generate the completions list. This means that the hook
310 (lambda () 295 (lambda ()
311 (pcomplete-here (pcomplete-executables)))) 296 (pcomplete-here (pcomplete-executables))))
312 "Function called for completing the initial command argument." 297 "Function called for completing the initial command argument."
313 :type 'function 298 :type 'function)
314 :group 'pcomplete)
315 299
316(defcustom pcomplete-command-name-function 'pcomplete-command-name 300(defcustom pcomplete-command-name-function #'pcomplete-command-name
317 "Function called for determining the current command name." 301 "Function called for determining the current command name."
318 :type 'function 302 :type 'function)
319 :group 'pcomplete)
320 303
321(defcustom pcomplete-default-completion-function 304(defcustom pcomplete-default-completion-function
322 (function 305 (function
@@ -324,16 +307,14 @@ generate the completions list. This means that the hook
324 (while (pcomplete-here (pcomplete-entries))))) 307 (while (pcomplete-here (pcomplete-entries)))))
325 "Function called when no completion rule can be found. 308 "Function called when no completion rule can be found.
326This function is used to generate completions for every argument." 309This function is used to generate completions for every argument."
327 :type 'function 310 :type 'function)
328 :group 'pcomplete)
329 311
330(defcustom pcomplete-use-paring t 312(defcustom pcomplete-use-paring t
331 "If t, pare alternatives that have already been used. 313 "If t, pare alternatives that have already been used.
332If nil, you will always see the completion set of possible options, no 314If nil, you will always see the completion set of possible options, no
333matter which of those options have already been used in previous 315matter which of those options have already been used in previous
334command arguments." 316command arguments."
335 :type 'boolean 317 :type 'boolean)
336 :group 'pcomplete)
337 318
338(defcustom pcomplete-termination-string " " 319(defcustom pcomplete-termination-string " "
339 "A string that is inserted after any completion or expansion. 320 "A string that is inserted after any completion or expansion.
@@ -342,8 +323,7 @@ words separated by spaces. However, if your list uses a different
342separator character, or if the completion occurs in a word that is 323separator character, or if the completion occurs in a word that is
343already terminated by a character, this variable should be locally 324already terminated by a character, this variable should be locally
344modified to be an empty string, or the desired separation string." 325modified to be an empty string, or the desired separation string."
345 :type 'string 326 :type 'string)
346 :group 'pcomplete)
347 327
348;;; Internal Variables: 328;;; Internal Variables:
349 329
@@ -528,6 +508,7 @@ Same as `pcomplete' but using the standard completion UI."
528 "Support extensible programmable completion. 508 "Support extensible programmable completion.
529To use this function, just bind the TAB key to it, or add it to your 509To use this function, just bind the TAB key to it, or add it to your
530completion functions list (it should occur fairly early in the list)." 510completion functions list (it should occur fairly early in the list)."
511 (declare (obsolete "use completion-at-point and pcomplete-completions-at-point" "27.1"))
531 (interactive "p") 512 (interactive "p")
532 (if (and interactively 513 (if (and interactively
533 pcomplete-cycle-completions 514 pcomplete-cycle-completions
@@ -579,7 +560,8 @@ completion functions list (it should occur fairly early in the list)."
579This will modify the current buffer." 560This will modify the current buffer."
580 (interactive) 561 (interactive)
581 (let ((pcomplete-expand-before-complete t)) 562 (let ((pcomplete-expand-before-complete t))
582 (pcomplete))) 563 (with-suppressed-warnings ((obsolete pcomplete))
564 (pcomplete))))
583 565
584;;;###autoload 566;;;###autoload
585(defun pcomplete-continue () 567(defun pcomplete-continue ()
@@ -596,7 +578,8 @@ This will modify the current buffer."
596 (interactive) 578 (interactive)
597 (let ((pcomplete-expand-before-complete t) 579 (let ((pcomplete-expand-before-complete t)
598 (pcomplete-expand-only-p t)) 580 (pcomplete-expand-only-p t))
599 (pcomplete) 581 (with-suppressed-warnings ((obsolete pcomplete))
582 (pcomplete))
600 (when (and pcomplete-current-completions 583 (when (and pcomplete-current-completions
601 (> (length pcomplete-current-completions) 0)) ;?? 584 (> (length pcomplete-current-completions) 0)) ;??
602 (delete-char (- pcomplete-last-completion-length)) 585 (delete-char (- pcomplete-last-completion-length))
@@ -611,9 +594,11 @@ This will modify the current buffer."
611;;;###autoload 594;;;###autoload
612(defun pcomplete-help () 595(defun pcomplete-help ()
613 "Display any help information relative to the current argument." 596 "Display any help information relative to the current argument."
597 (declare (obsolete "use completion-help-at-point and pcomplete-completions-at-point" "27.1"))
614 (interactive) 598 (interactive)
615 (let ((pcomplete-show-help t)) 599 (let ((pcomplete-show-help t))
616 (pcomplete))) 600 (with-suppressed-warnings ((obsolete pcomplete))
601 (pcomplete))))
617 602
618;;;###autoload 603;;;###autoload
619(defun pcomplete-list () 604(defun pcomplete-list ()
@@ -626,7 +611,8 @@ This will modify the current buffer."
626 (setq pcomplete-current-completions nil 611 (setq pcomplete-current-completions nil
627 pcomplete-last-completion-raw nil)) 612 pcomplete-last-completion-raw nil))
628 (let ((pcomplete-show-list t)) 613 (let ((pcomplete-show-list t))
629 (pcomplete))) 614 (with-suppressed-warnings ((obsolete pcomplete))
615 (pcomplete))))
630 616
631;;; Internal Functions: 617;;; Internal Functions:
632 618
@@ -751,9 +737,9 @@ COMPLETEF-SYM should be the symbol where the
751dynamic-complete-functions are kept. For comint mode itself, 737dynamic-complete-functions are kept. For comint mode itself,
752this is `comint-dynamic-complete-functions'." 738this is `comint-dynamic-complete-functions'."
753 (set (make-local-variable 'pcomplete-parse-arguments-function) 739 (set (make-local-variable 'pcomplete-parse-arguments-function)
754 'pcomplete-parse-comint-arguments) 740 #'pcomplete-parse-comint-arguments)
755 (add-hook 'completion-at-point-functions 741 (add-hook 'completion-at-point-functions
756 'pcomplete-completions-at-point nil 'local) 742 #'pcomplete-completions-at-point nil 'local)
757 (set (make-local-variable completef-sym) 743 (set (make-local-variable completef-sym)
758 (copy-sequence (symbol-value completef-sym))) 744 (copy-sequence (symbol-value completef-sym)))
759 (let* ((funs (symbol-value completef-sym)) 745 (let* ((funs (symbol-value completef-sym))
@@ -915,12 +901,12 @@ component, `default-directory' is used as the basis for completion."
915 (or (eq action t) 901 (or (eq action t)
916 (eq (car-safe action) 'boundaries)))) 902 (eq (car-safe action) 'boundaries))))
917 (let ((newstring 903 (let ((newstring
918 (mapconcat 'identity (nreverse (cons string strings)) ""))) 904 (mapconcat #'identity (nreverse (cons string strings)) "")))
919 ;; FIXME: We could also try to return unexpanded envvars. 905 ;; FIXME: We could also try to return unexpanded envvars.
920 (complete-with-action action table newstring pred)) 906 (complete-with-action action table newstring pred))
921 (let* ((envpos (apply #'+ (mapcar #' length strings))) 907 (let* ((envpos (apply #'+ (mapcar #' length strings)))
922 (newstring 908 (newstring
923 (mapconcat 'identity (nreverse (cons string strings)) "")) 909 (mapconcat #'identity (nreverse (cons string strings)) ""))
924 (bounds (completion-boundaries newstring table pred 910 (bounds (completion-boundaries newstring table pred
925 (or (cdr-safe action) "")))) 911 (or (cdr-safe action) ""))))
926 (if (>= (car bounds) envpos) 912 (if (>= (car bounds) envpos)
@@ -950,7 +936,7 @@ component, `default-directory' is used as the basis for completion."
950 936
951(defsubst pcomplete-dirs (&optional regexp) 937(defsubst pcomplete-dirs (&optional regexp)
952 "Complete amongst a list of directories." 938 "Complete amongst a list of directories."
953 (pcomplete-entries regexp 'file-directory-p)) 939 (pcomplete-entries regexp #'file-directory-p))
954 940
955;; generation of completion lists 941;; generation of completion lists
956 942
@@ -1055,7 +1041,7 @@ See the documentation for `pcomplete-here'."
1055 (setq pcomplete-stub stub)) 1041 (setq pcomplete-stub stub))
1056 (if (or (eq paring t) (eq paring 0)) 1042 (if (or (eq paring t) (eq paring 0))
1057 (setq pcomplete-seen nil) 1043 (setq pcomplete-seen nil)
1058 (setq pcomplete-norm-func (or paring 'file-truename))) 1044 (setq pcomplete-norm-func (or paring #'file-truename)))
1059 (unless form-only 1045 (unless form-only
1060 (run-hooks 'pcomplete-try-first-hook)) 1046 (run-hooks 'pcomplete-try-first-hook))
1061 (throw 'pcomplete-completions 1047 (throw 'pcomplete-completions
@@ -1128,7 +1114,7 @@ Typing SPC flushes the help buffer."
1128 pcomplete-restore-window-delay) 1114 pcomplete-restore-window-delay)
1129 (setq pcomplete-window-restore-timer 1115 (setq pcomplete-window-restore-timer
1130 (run-with-timer pcomplete-restore-window-delay nil 1116 (run-with-timer pcomplete-restore-window-delay nil
1131 'pcomplete-restore-windows)))))) 1117 #'pcomplete-restore-windows))))))
1132 1118
1133;; insert completion at point 1119;; insert completion at point
1134 1120
@@ -1181,12 +1167,12 @@ extra checking, and munging of the COMPLETIONS list."
1181 ;; pare it down, if applicable 1167 ;; pare it down, if applicable
1182 (when (and pcomplete-use-paring pcomplete-seen) 1168 (when (and pcomplete-use-paring pcomplete-seen)
1183 (setq pcomplete-seen 1169 (setq pcomplete-seen
1184 (mapcar 'directory-file-name pcomplete-seen)) 1170 (mapcar #'directory-file-name pcomplete-seen))
1185 (dolist (p pcomplete-seen) 1171 (dolist (p pcomplete-seen)
1186 (add-to-list 'pcomplete-seen 1172 (add-to-list 'pcomplete-seen
1187 (funcall pcomplete-norm-func p))) 1173 (funcall pcomplete-norm-func p)))
1188 (setq completions 1174 (setq completions
1189 (apply-partially 'completion-table-with-predicate 1175 (apply-partially #'completion-table-with-predicate
1190 completions 1176 completions
1191 (when pcomplete-seen 1177 (when pcomplete-seen
1192 (lambda (f) 1178 (lambda (f)
@@ -1269,8 +1255,10 @@ If specific documentation can't be given, be generic."
1269 (if (listp pcomplete-help) 1255 (if (listp pcomplete-help)
1270 (message "%s" (eval pcomplete-help)) 1256 (message "%s" (eval pcomplete-help))
1271 (save-window-excursion (info)) 1257 (save-window-excursion (info))
1258 (declare-function Info-goto-node
1259 "info" (nodename &optional fork strict-case))
1272 (switch-to-buffer-other-window "*info*") 1260 (switch-to-buffer-other-window "*info*")
1273 (funcall (symbol-function 'Info-goto-node) pcomplete-help)) 1261 (funcall #'Info-goto-node pcomplete-help))
1274 (if pcomplete-man-function 1262 (if pcomplete-man-function
1275 (let ((cmd (funcall pcomplete-command-name-function))) 1263 (let ((cmd (funcall pcomplete-command-name-function)))
1276 (if (and cmd (> (length cmd) 0)) 1264 (if (and cmd (> (length cmd) 0))
@@ -1297,7 +1285,7 @@ If specific documentation can't be given, be generic."
1297(defun pcomplete-process-result (cmd &rest args) 1285(defun pcomplete-process-result (cmd &rest args)
1298 "Call CMD using `call-process' and return the simplest result." 1286 "Call CMD using `call-process' and return the simplest result."
1299 (with-temp-buffer 1287 (with-temp-buffer
1300 (apply 'call-process cmd nil t nil args) 1288 (apply #'call-process cmd nil t nil args)
1301 (skip-chars-backward "\n") 1289 (skip-chars-backward "\n")
1302 (buffer-substring (point-min) (point)))) 1290 (buffer-substring (point-min) (point))))
1303 1291