Mercurial > emacs
comparison lisp/minibuffer.el @ 105589:e84a6a47bcb9
(completion--file-name-table): Return nil if there's
no file completion, even if substitute-in-file-name changed
the string (bug#4708).
author | Stefan Monnier <monnier@iro.umontreal.ca> |
---|---|
date | Wed, 14 Oct 2009 03:05:06 +0000 |
parents | 13f171fbff05 |
children | 117859152fa5 |
comparison
equal
deleted
inserted
replaced
105588:2586fdd484bd | 105589:e84a6a47bcb9 |
---|---|
1076 | 1076 |
1077 (cond | 1077 (cond |
1078 ((null action) | 1078 ((null action) |
1079 (let ((comp (file-name-completion name realdir | 1079 (let ((comp (file-name-completion name realdir |
1080 read-file-name-predicate))) | 1080 read-file-name-predicate))) |
1081 (if (stringp comp) | 1081 (cond |
1082 ;; Requote the $s before returning the completion. | 1082 ((stringp comp) |
1083 (minibuffer--double-dollars (concat specdir comp)) | 1083 ;; Requote the $s before returning the completion. |
1084 (minibuffer--double-dollars (concat specdir comp))) | |
1085 (comp | |
1084 ;; Requote the $s before checking for changes. | 1086 ;; Requote the $s before checking for changes. |
1085 (setq str (minibuffer--double-dollars str)) | 1087 (setq str (minibuffer--double-dollars str)) |
1086 (if (string-equal string str) | 1088 (if (string-equal string str) |
1087 comp | 1089 comp |
1088 ;; If there's no real completion, but substitute-in-file-name | 1090 ;; If there's no real completion, but substitute-in-file-name |
1089 ;; changed the string, then return the new string. | 1091 ;; changed the string, then return the new string. |
1090 str)))) | 1092 str))))) |
1091 | 1093 |
1092 ((eq action t) | 1094 ((eq action t) |
1093 (let ((all (file-name-all-completions name realdir))) | 1095 (let ((all (file-name-all-completions name realdir))) |
1094 | 1096 |
1095 ;; Check the predicate, if necessary. | 1097 ;; Check the predicate, if necessary. |