emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] /srv/bzr/emacs/trunk r108248: * lisp/minibuffer.el (comple


From: Stefan Monnier
Subject: [Emacs-diffs] /srv/bzr/emacs/trunk r108248: * lisp/minibuffer.el (completion--sifn-requote): Fix last change.
Date: Tue, 15 May 2012 21:57:20 -0400
User-agent: Bazaar (2.3.1)

------------------------------------------------------------
revno: 108248
committer: Stefan Monnier <address@hidden>
branch nick: trunk
timestamp: Tue 2012-05-15 21:57:20 -0400
message:
  * lisp/minibuffer.el (completion--sifn-requote): Fix last change.
  (minibuffer-local-must-match-filename-map):
  Move define-obsolete-variable-alias before its var.
modified:
  lisp/ChangeLog
  lisp/minibuffer.el
=== modified file 'lisp/ChangeLog'
--- a/lisp/ChangeLog    2012-05-15 18:45:27 +0000
+++ b/lisp/ChangeLog    2012-05-16 01:57:20 +0000
@@ -1,3 +1,9 @@
+2012-05-16  Stefan Monnier  <address@hidden>
+
+       * minibuffer.el (completion--sifn-requote): Fix last change.
+       (minibuffer-local-must-match-filename-map):
+       Move define-obsolete-variable-alias before its var.
+
 2012-05-15  Stefan Monnier  <address@hidden>
 
        * emacs-lisp/pcase.el (pcase-let*, pcase-let): Fix edebug spec.

=== modified file 'lisp/minibuffer.el'
--- a/lisp/minibuffer.el        2012-05-15 18:07:36 +0000
+++ b/lisp/minibuffer.el        2012-05-16 01:57:20 +0000
@@ -1952,10 +1952,10 @@
 Gets combined either with `minibuffer-local-completion-map' or
 with `minibuffer-local-must-match-map'.")
 
+(define-obsolete-variable-alias 'minibuffer-local-must-match-filename-map
+  'minibuffer-local-filename-must-match-map "23.1")
 (defvar minibuffer-local-filename-must-match-map (make-sparse-keymap))
 (make-obsolete-variable 'minibuffer-local-filename-must-match-map nil "24.1")
-(define-obsolete-variable-alias 'minibuffer-local-must-match-filename-map
-  'minibuffer-local-filename-must-match-map "23.1")
 
 (let ((map minibuffer-local-ns-map))
   (define-key map " " 'exit-minibuffer)
@@ -2132,13 +2132,15 @@
   ;; Kind of like in rfn-eshadow-update-overlay, only worse.
   (let ((qpos 0))
     ;; Handle substitute-in-file-name's truncation behavior.
-    (while (and (string-match "[\\/][~/\\]" qstr qpos)
-                ;; Hopefully our regexp covers all truncation cases.
-                ;; Also let's make sure sifn indeed truncates here.
-                (let ((tpos (1+ (match-beginning 0))))
-                  (equal (substitute-in-file-name qstr)
-                         (substitute-in-file-name (substring qstr tpos)))))
-      (setq qpos tpos))
+    (let (tpos)
+      (while (and (string-match "[\\/][~/\\]" qstr qpos)
+                  ;; Hopefully our regexp covers all truncation cases.
+                  ;; Also let's make sure sifn indeed truncates here.
+                  (progn
+                    (setq tpos (1+ (match-beginning 0)))
+                    (equal (substitute-in-file-name qstr)
+                           (substitute-in-file-name (substring qstr tpos)))))
+        (setq qpos tpos)))
     ;; `upos' is relative to the position corresponding to `qpos' in
     ;; (substitute-in-file-name qstr), so as qpos moves forward, upos
     ;; gets smaller.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]