diff options
| -rw-r--r-- | lisp/minibuffer.el | 17 |
1 files changed, 11 insertions, 6 deletions
diff --git a/lisp/minibuffer.el b/lisp/minibuffer.el index a59fac6d556..163bebb5028 100644 --- a/lisp/minibuffer.el +++ b/lisp/minibuffer.el | |||
| @@ -1381,12 +1381,17 @@ or a symbol chosen among `any', `star', `point'." | |||
| 1381 | (mapconcat | 1381 | (mapconcat |
| 1382 | (lambda (x) | 1382 | (lambda (x) |
| 1383 | (case x | 1383 | (case x |
| 1384 | ((star any point) | 1384 | ((star any point) |
| 1385 | (if (if (consp group) (memq x group) group) | 1385 | (if (if (consp group) (memq x group) group) |
| 1386 | "\\(.*?\\)" ".*?")) | 1386 | "\\(.*?\\)" |
| 1387 | (t (regexp-quote x)))) | 1387 | ".*?")) |
| 1388 | pattern | 1388 | (t |
| 1389 | "")))) | 1389 | (if (and completion-ignore-case |
| 1390 | (string-match "[[:alpha:]]" x)) | ||
| 1391 | (format "[%s%s]" (downcase x) (upcase x)) | ||
| 1392 | (regexp-quote x))))) | ||
| 1393 | pattern | ||
| 1394 | "")))) | ||
| 1390 | ;; Avoid pathological backtracking. | 1395 | ;; Avoid pathological backtracking. |
| 1391 | (while (string-match "\\.\\*\\?\\(?:\\\\[()]\\)*\\(\\.\\*\\?\\)" re) | 1396 | (while (string-match "\\.\\*\\?\\(?:\\\\[()]\\)*\\(\\.\\*\\?\\)" re) |
| 1392 | (setq re (replace-match "" t t re 1))) | 1397 | (setq re (replace-match "" t t re 1))) |