emacs-diffs
[Top][All Lists]
Advanced

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

[Emacs-diffs] trunk r117412: Merge from emacs-24; up to r117309


From: Glenn Morris
Subject: [Emacs-diffs] trunk r117412: Merge from emacs-24; up to r117309
Date: Thu, 26 Jun 2014 06:56:04 +0000
User-agent: Bazaar (2.6b2)

------------------------------------------------------------
revno: 117412 [merge]
revision-id: address@hidden
parent: address@hidden
parent: address@hidden
committer: Glenn Morris <address@hidden>
branch nick: trunk
timestamp: Wed 2014-06-25 23:55:15 -0700
message:
  Merge from emacs-24; up to r117309
modified:
  admin/ChangeLog                changelog-20091113204419-o5vbwnq5f7feedwu-2226
  admin/authors.el               authors.el-20091113204419-o5vbwnq5f7feedwu-1898
  admin/notes/unicode            unicode-20091113204419-o5vbwnq5f7feedwu-8579
  lisp/ChangeLog                 changelog-20091113204419-o5vbwnq5f7feedwu-1432
  lisp/ChangeLog.16              changelog.16-20130618111706-x8cck4o4rjixg8cl-1
  lisp/calendar/todo-mode.el     todos.el-20120911155047-0ytqo2nidwqquefa-1
  lisp/desktop.el                desktop.el-20091113204419-o5vbwnq5f7feedwu-591
  lisp/emacs-lisp/cl-macs.el     clmacs.el-20091113204419-o5vbwnq5f7feedwu-612
  lisp/emacs-lisp/package.el     package.el-20100617020707-ybavz666awsxwin6-2
  lisp/gnus/ChangeLog            changelog-20091113204419-o5vbwnq5f7feedwu-1433
  lisp/gnus/mm-util.el           mmutil.el-20091113204419-o5vbwnq5f7feedwu-1974
  lisp/help-fns.el               helpfns.el-20091113204419-o5vbwnq5f7feedwu-2354
  lisp/indent.el                 indent.el-20091113204419-o5vbwnq5f7feedwu-230
  lisp/progmodes/asm-mode.el     asmmode.el-20091113204419-o5vbwnq5f7feedwu-400
  lisp/progmodes/sh-script.el    shscript.el-20091113204419-o5vbwnq5f7feedwu-727
  lisp/ruler-mode.el             
rulermode.el-20091113204419-o5vbwnq5f7feedwu-2250
  lisp/textmodes/picture.el      picture.el-20091113204419-o5vbwnq5f7feedwu-213
  lisp/url/ChangeLog             changelog-20091113204419-o5vbwnq5f7feedwu-3116
  lisp/url/url-handlers.el       
urlhandlers.el-20091113204419-o5vbwnq5f7feedwu-2987
  lisp/url/url-http.el           urlhttp.el-20091113204419-o5vbwnq5f7feedwu-2989
  test/ChangeLog                 changelog-20091113204419-o5vbwnq5f7feedwu-8588
  test/automated/package-test.el 
packagetest.el-20130627091655-6mb005jio30t2i3i-1
  test/indent/shell.sh           shell.sh-20110209185043-iuyrh0is1gz0s4w6-1
=== modified file 'admin/ChangeLog'
--- a/admin/ChangeLog   2014-06-26 06:24:56 +0000
+++ b/admin/ChangeLog   2014-06-26 06:55:15 +0000
@@ -1,3 +1,8 @@
+2014-06-26  Eli Zaretskii  <address@hidden>
+
+       * notes/unicode: Some notes about what to do when a new Unicode
+       version is imported.
+
 2014-06-26  Glenn Morris  <address@hidden>
 
        * authors.el: Move here from ../lisp/emacs-lisp.

=== modified file 'admin/authors.el'
--- a/admin/authors.el  2014-06-26 06:24:56 +0000
+++ b/admin/authors.el  2014-06-26 06:55:15 +0000
@@ -622,11 +622,12 @@
     "temacs.opt" "descrip.mms" "compile.com" "link.com"
     "compact.el" "fadr.el"
     "calc/calc-maint.el"
+    "emacs-lisp/cl-specs.el"
     "emacs-lisp/eieio-comp.el"
     "erc-hecomplete.el"
     "eshell/esh-maint.el"
     "language/persian.el"
-    "meese.el" "iswitchb.el"
+    "ledit.el" "meese.el" "iswitchb.el" "longlines.el"
     "mh-exec.el" "mh-init.el" "mh-customize.el"
     "net/zone-mode.el" "xesam.el"
     "term/mac-win.el" "sup-mouse.el"
@@ -647,6 +648,7 @@
     "dns-mode.el" "run-at-time.el" "gnus-encrypt.el" "sha1-el.el"
     "gnus-gl.el" "gnus.sum.el" "proto-stream.el" "color.el" "color-lab.el"
     "eww.el" "shr-color.el" "shr.el" "earcon.el" "gnus-audio.el" "encrypt.el"
+    "format-spec.el" "gnus-move.el"
     ;; doc
     "getopt.c" "texindex.c" "news.texi" "vc.texi" "vc2-xtra.texi"
     "back.texi" "vol1.texi" "vol2.texi" "elisp-covers.texi" "two.el"
@@ -752,7 +754,11 @@
     ("progmodes/octave-inf.el" . "octave.el")
     ("progmodes/octave-mod.el" . "octave.el")
     ;; Obsolete.
+    ("emacs-lisp/assoc.el" . "assoc.el")
+    ("emacs-lisp/cust-print.el" . "cust-print.el")
+    ("mail/mailpost.el" . "mailpost.el")
     ("play/bruce.el" . "bruce.el")
+    ("play/yow.el" . "yow.el")
     ("patcomp.el" . "patcomp.el")
     ;; From lisp to etc/forms.
     ("forms-d2.el" . "forms-d2.el")
@@ -771,6 +777,7 @@
     ("build-install" . "build-ins.in")
     ("build-install.in" . "build-ins.in")
     ("unidata/Makefile" . "unidata/Makefile.in")
+    ("mac/uvs.el" . "unidata/uvs.el")
     ;; Moved from top to etc/
     ("CONTRIBUTE" . "CONTRIBUTE")
     ("FTP" . "FTP")

=== modified file 'admin/notes/unicode'
--- a/admin/notes/unicode       2014-03-22 22:52:47 +0000
+++ b/admin/notes/unicode       2014-06-26 06:55:15 +0000
@@ -3,6 +3,39 @@
 Copyright (C) 2002-2014 Free Software Foundation, Inc.
 See the end of the file for license conditions.
 
+Importing a new Unicode Standard version into Emacs
+-------------------------------------------------------------
+
+Emacs uses the following files from the Unicode Character Database
+(a.k.a. "UCD):
+
+  . UnicodeData.txt
+  . BidiMirroring.txt
+  . IVD_Sequences.txt
+
+First, these files need to be copied into admin/unidata/, and then
+Emacs should be rebuilt for them to take effect.  Rebuilding Emacs
+updates several derived files elsewhere in the Emacs source tree,
+mainly in lisp/international/.
+
+When Emacs is rebuilt for the first time after importing the new
+files, pay attention to any warning or error messages.  In particular,
+admin/unidata/unidata-gen.el will complain if UnicodeData.txt defines
+new bidirectional attributes of characters, because unidata-gen.el,
+bidi.c and dispextern.h need to be updated in that case; failure to do
+so will cause aborts in redisplay.
+
+Next, review the changes in UnicodeData.txt vs the previous version
+used by Emacs.  Any changes, be it introduction of new scripts or
+addition of codepoints to existing scripts, need corresponding changes
+in the data used for filling char-script-table, see characters.el
+around line 1300.  Other databases and settings in characters.el, such
+as the data for char-width-table, might also need changes.
+
+Any new scripts added by UnicodeData.txt will also need updates to
+script-representative-chars defined in fontset.el.  Other databases in
+fontset.el might also need to be updated as needed.
+
 Problems, fixmes and other unicode-related issues
 -------------------------------------------------------------
 

=== modified file 'lisp/ChangeLog'
--- a/lisp/ChangeLog    2014-06-26 06:45:10 +0000
+++ b/lisp/ChangeLog    2014-06-26 06:55:15 +0000
@@ -1,5 +1,61 @@
 2014-06-26  Glenn Morris  <address@hidden>
 
+       * emacs-lisp/cl-macs.el (help-add-fundoc-usage):
+       Remove outdated declaration.
+
+       * emacs-lisp/authors.el (authors-valid-file-names)
+       (authors-renamed-files-alist): Additions.
+
+2014-06-26  Leo Liu  <address@hidden>
+
+       * textmodes/picture.el (picture-set-tab-stops):
+       * ruler-mode.el (ruler-mode-mouse-add-tab-stop)
+       (ruler-mode-ruler): Fix to work with nil tab-stop-list.
+
+       * progmodes/asm-mode.el (asm-calculate-indentation): Use
+       indent-next-tab-stop.
+
+       * indent.el (indent-accumulate-tab-stops): New function.
+
+2014-06-26  Stefan Monnier  <address@hidden>
+
+       * emacs-lisp/package.el (package-list-unsigned): New var (bug#17625).
+       (package-desc-status): Obey it.
+
+2014-06-26  Stephen Berman  <address@hidden>
+
+       * calendar/todo-mode.el: Fix two bugs.
+       (todo-insert-item--basic): If user cancels item insertion to
+       another category before setting priority, show original category
+       whether it is in the same or a different file.
+       (todo-set-item-priority): After selecting category, instead of
+       moving point to top, which extends an active region, restore it.
+
+2014-06-26  Stefan Monnier  <address@hidden>
+
+       * help-fns.el (describe-function-1): Check file-name is a string before
+       calling help-fns--autoloaded-p (bug#17564).
+
+2014-06-26  Juri Linkov  <address@hidden>
+
+       * desktop.el (desktop-auto-save-enable)
+       (desktop-auto-save-disable): New functions.
+       (desktop-save-mode, desktop-auto-save-timeout): Use them.
+       (desktop-read): Disable the autosave before loading the desktop,
+       and enable afterwards.  (Bug#17351)
+
+2014-06-26  Stefan Monnier  <address@hidden>
+
+       Fix some indentation problem with \; and pipes (bug#17842).
+       * progmodes/sh-script.el (sh-mode-syntax-table): Set syntax of ;|&.
+       (sh-smie--default-forward-token, sh-smie--default-backward-token):
+       New functions.
+       (sh-smie-sh-forward-token, sh-smie-sh-backward-token)
+       (sh-smie-rc-forward-token, sh-smie-rc-backward-token): Use them.
+       (sh-smie-sh-rules): Fix indentation of a pipe at BOL.
+
+2014-06-26  Glenn Morris  <address@hidden>
+
        * emacs-lisp/find-func.el (find-function-C-source-directory):
        Use file-accessible-directory-p.
 
@@ -12194,7 +12250,7 @@
 
 2013-07-07  Michael Kifer  <address@hidden>
 
-       * ediff.el (ediff-version): Version update.
+       * vc/ediff.el (ediff-version): Version update.
        (ediff-files-command, ediff3-files-command, ediff-merge-command)
        (ediff-merge-with-ancestor-command, ediff-directories-command)
        (ediff-directories3-command, ediff-merge-directories-command)
@@ -12202,19 +12258,21 @@
        All are command-line interfaces to ediff: to facilitate calling
        Emacs with the appropriate ediff functions invoked.
 
-       * viper-cmd.el (viper-del-forward-char-in-insert): New function.
+       * emulation/viper-cmd.el (viper-del-forward-char-in-insert):
+       New function.
        (viper-save-kill-buffer): Check if buffer is modified.
 
-       * viper.el (viper-version): Version update.
+       * emulation/viper.el (viper-version): Version update.
        (viper-emacs-state-mode-list): Add egg-status-buffer-mode.
 
 2013-07-07  Stefan Monnier  <address@hidden>
 
        * faces.el (tty-run-terminal-initialization): Run new tty-setup-hook.
-       * viper-cmd.el (viper-envelop-ESC-key): Remove function.
+       * emulation/viper-cmd.el (viper-envelop-ESC-key): Remove function.
        (viper-intercept-ESC-key): Simplify.
-       * viper-keym.el (viper-ESC-key): Make it a constant, don't use kbd.
-       * viper.el (viper--tty-ESC-filter, viper--lookup-key)
+       * emulation/viper-keym.el (viper-ESC-key): Make it a constant,
+       don't use kbd.
+       * emulation/viper.el (viper--tty-ESC-filter, viper--lookup-key)
        (viper-catch-tty-ESC, viper-uncatch-tty-ESC)
        (viper-setup-ESC-to-escape): New functions.
        (viper-go-away, viper-set-hooks): Call viper-setup-ESC-to-escape.

=== modified file 'lisp/ChangeLog.16'
--- a/lisp/ChangeLog.16 2014-04-20 14:45:19 +0000
+++ b/lisp/ChangeLog.16 2014-06-26 00:34:54 +0000
@@ -8501,7 +8501,7 @@
 
 2012-07-25  Jay Belanger  <address@hidden>
 
-       * calc-alg.el (math-simplify-divide): Don't cross multiply
+       * calc/calc-alg.el (math-simplify-divide): Don't cross multiply
        in an equation when the lhs is a variable.
 
 2012-07-24  Julien Danjou  <address@hidden>

=== modified file 'lisp/calendar/todo-mode.el'
--- a/lisp/calendar/todo-mode.el        2014-05-23 16:54:35 +0000
+++ b/lisp/calendar/todo-mode.el        2014-06-25 12:06:00 +0000
@@ -1962,13 +1962,12 @@
            ;; If user cancels before setting priority, restore
            ;; display.
            (unless item-added
-             (if ocat
-                 (progn
-                   (unless (equal cat ocat)
-                     (todo-category-number ocat)
-                     (todo-category-select))
-                   (and done-only (todo-toggle-view-done-only)))
-               (set-window-buffer (selected-window) (set-buffer obuf)))
+             (set-window-buffer (selected-window) (set-buffer obuf))
+             (when ocat
+               (unless (equal cat ocat)
+                 (todo-category-number ocat)
+                 (todo-category-select))
+               (and done-only (todo-toggle-view-done-only)))
              (goto-char opoint))
            ;; If the todo items section is not visible when the
            ;; insertion command is called (either because only done
@@ -2553,9 +2552,9 @@
                (goto-char (point-min))
                (setq done (re-search-forward todo-done-string-start nil t))))
            (let ((todo-show-with-done done))
-             (todo-category-select)
-             ;; Keep top of category in view while setting priority.
-             (goto-char (point-min)))))
+             ;; Keep current item or top of moved to category in view
+             ;; while setting priority.
+             (save-excursion (todo-category-select)))))
        ;; Prompt for priority only when the category has at least one
        ;; todo item.
        (when (> maxnum 1)

=== modified file 'lisp/desktop.el'
--- a/lisp/desktop.el   2014-06-06 23:38:40 +0000
+++ b/lisp/desktop.el   2014-06-24 23:23:41 +0000
@@ -174,11 +174,8 @@
   :global t
   :group 'desktop
   (if desktop-save-mode
-      (when (and (integerp desktop-auto-save-timeout)
-                (> desktop-auto-save-timeout 0))
-       (add-hook 'window-configuration-change-hook 
'desktop-auto-save-set-timer))
-    (remove-hook 'window-configuration-change-hook 
'desktop-auto-save-set-timer)
-    (desktop-auto-save-cancel-timer)))
+      (desktop-auto-save-enable)
+    (desktop-auto-save-disable)))
 
 (defun desktop-save-mode-off ()
   "Disable `desktop-save-mode'.  Provided for use in hooks."
@@ -219,9 +216,8 @@
          (set-default symbol value)
          (ignore-errors
           (if (and (integerp value) (> value 0))
-              (add-hook 'window-configuration-change-hook 
'desktop-auto-save-set-timer)
-            (remove-hook 'window-configuration-change-hook 
'desktop-auto-save-set-timer)
-            (desktop-auto-save-cancel-timer))))
+              (desktop-auto-save-enable value)
+            (desktop-auto-save-disable))))
   :group 'desktop
   :version "24.4")
 
@@ -1132,6 +1128,10 @@
                (unless desktop-dirname
                  (message "Desktop file in use; not loaded.")))
            (desktop-lazy-abort)
+           ;; Temporarily disable the autosave that will leave it
+           ;; disabled when loading the desktop fails with errors,
+           ;; thus not overwriting the desktop with broken contents.
+           (desktop-auto-save-disable)
            ;; Evaluate desktop buffer and remember when it was modified.
            (load (desktop-full-file-name) t t t)
            (setq desktop-file-modtime (nth 5 (file-attributes 
(desktop-full-file-name))))
@@ -1184,6 +1184,7 @@
                                  (set-window-prev-buffers window nil)
                                  (set-window-next-buffers window nil))))
            (setq desktop-saved-frameset nil)
+           (desktop-auto-save-enable)
            t))
       ;; No desktop file found.
       (desktop-clear)
@@ -1230,6 +1231,15 @@
 ;; Auto-Saving.
 (defvar desktop-auto-save-timer nil)
 
+(defun desktop-auto-save-enable (&optional timeout)
+  (when (and (integerp (or timeout desktop-auto-save-timeout))
+            (> (or timeout desktop-auto-save-timeout) 0))
+    (add-hook 'window-configuration-change-hook 'desktop-auto-save-set-timer)))
+
+(defun desktop-auto-save-disable ()
+  (remove-hook 'window-configuration-change-hook 'desktop-auto-save-set-timer)
+  (desktop-auto-save-cancel-timer))
+
 (defun desktop-auto-save ()
   "Save the desktop periodically.
 Called by the timer created in `desktop-auto-save-set-timer'."

=== modified file 'lisp/emacs-lisp/cl-macs.el'
--- a/lisp/emacs-lisp/cl-macs.el        2014-06-05 23:08:59 +0000
+++ b/lisp/emacs-lisp/cl-macs.el        2014-06-26 06:55:15 +0000
@@ -382,8 +382,6 @@
        (if (car res) `(progn ,(car res) ,form) form))
     `(function ,func)))
 
-(declare-function help-add-fundoc-usage "help-fns" (docstring arglist))
-
 (defun cl--make-usage-var (x)
   "X can be a var or a (destructuring) lambda-list."
   (cond

=== modified file 'lisp/emacs-lisp/package.el'
--- a/lisp/emacs-lisp/package.el        2014-06-08 00:35:27 +0000
+++ b/lisp/emacs-lisp/package.el        2014-06-26 06:55:15 +0000
@@ -836,6 +836,8 @@
                                    sig))
                              (epg-context-result-for context 'verify)))))
       (if (null good-signatures)
+          ;; FIXME: Only signal an error if the signature is invalid, not if we
+          ;; simply lack the key needed to check the sig!
           (error "Failed to verify signature %s: %S"
                  sig-file
                  (mapcar #'epg-signature-to-string
@@ -1664,6 +1666,9 @@
 (defvar package-list-unversioned nil
   "If non-nil include packages that don't have a version in `list-package'.")
 
+(defvar package-list-unsigned nil
+  "If non-nil, mention in the list which packages were installed w/o 
signature.")
+
 (defun package-desc-status (pkg-desc)
   (let* ((name (package-desc-name pkg-desc))
          (dir (package-desc-dir pkg-desc))
@@ -1684,9 +1689,8 @@
      (dir                               ;One of the installed packages.
       (cond
        ((not (file-exists-p (package-desc-dir pkg-desc))) "deleted")
-       ((eq pkg-desc (cadr (assq name package-alist))) (if signed
-                                                          "installed"
-                                                        "unsigned"))
+       ((eq pkg-desc (cadr (assq name package-alist)))
+        (if (or (not package-list-unsigned) signed) "installed" "unsigned"))
        (t "obsolete")))
      (t
       (let* ((ins (cadr (assq name package-alist)))
@@ -1696,9 +1700,9 @@
           (if (memq name package-menu--new-package-list)
               "new" "available"))
          ((version-list-< version ins-v) "obsolete")
-         ((version-list-= version ins-v) (if signed
-                                            "installed"
-                                          "unsigned"))))))))
+         ((version-list-= version ins-v)
+          (if (or (not package-list-unsigned) signed)
+              "installed" "unsigned"))))))))
 
 (defun package-menu--refresh (&optional packages keywords)
   "Re-populate the `tabulated-list-entries'.

=== modified file 'lisp/gnus/ChangeLog'
--- a/lisp/gnus/ChangeLog       2014-06-24 07:15:26 +0000
+++ b/lisp/gnus/ChangeLog       2014-06-26 06:55:15 +0000
@@ -1,3 +1,7 @@
+2014-06-26  Glenn Morris  <address@hidden>
+
+       * mm-util.el (help-function-arglist): Remove outdated declaration.
+
 2014-06-24  Andreas Schwab  <address@hidden>
 
        * html2text.el (html2text-get-attr): Rewrite to handle spaces in quoted

=== modified file 'lisp/gnus/mm-util.el'
--- a/lisp/gnus/mm-util.el      2014-03-23 23:13:36 +0000
+++ b/lisp/gnus/mm-util.el      2014-06-26 06:55:15 +0000
@@ -1374,8 +1374,6 @@
     (write-region start end filename append visit lockname)))
 
 (autoload 'gmm-write-region "gmm-utils")
-(declare-function help-function-arglist "help-fns"
-                 (def &optional preserve-names))
 
 ;; It is not a MIME function, but some MIME functions use it.
 (if (and (fboundp 'make-temp-file)

=== modified file 'lisp/help-fns.el'
--- a/lisp/help-fns.el  2014-05-08 03:41:21 +0000
+++ b/lisp/help-fns.el  2014-06-26 06:55:15 +0000
@@ -483,7 +483,7 @@
         (beg (if (and (or (byte-code-function-p def)
                           (keymapp def)
                           (memq (car-safe def) '(macro lambda closure)))
-                      file-name
+                      (stringp file-name)
                       (help-fns--autoloaded-p function file-name))
                  (if (commandp def)
                      "an interactive autoloaded "

=== modified file 'lisp/indent.el'
--- a/lisp/indent.el    2014-06-23 23:09:20 +0000
+++ b/lisp/indent.el    2014-06-25 23:53:37 +0000
@@ -677,6 +677,13 @@
                             (if (<= column last) -1 (/ (- column last 1) step))
                           (1+ (/ (- column last) step)))))))))
 
+(defun indent-accumulate-tab-stops (limit)
+  "Get a list of tab stops before LIMIT (inclusive)."
+  (let ((tab 0) (tab-stops))
+    (while (<= (setq tab (indent-next-tab-stop tab)) limit)
+      (push tab tab-stops))
+    (nreverse tab-stops)))
+
 (defun tab-to-tab-stop ()
   "Insert spaces or tabs to next defined tab-stop column.
 The variable `tab-stop-list' is a list of columns at which there are tab stops.

=== modified file 'lisp/progmodes/asm-mode.el'
--- a/lisp/progmodes/asm-mode.el        2014-02-10 01:34:22 +0000
+++ b/lisp/progmodes/asm-mode.el        2014-06-25 23:53:37 +0000
@@ -172,7 +172,7 @@
    ;; Simple `;' comments go to the comment-column.
    (and (looking-at "\\s<\\(\\S<\\|\\'\\)") comment-column)
    ;; The rest goes at the first tab stop.
-   (or (car tab-stop-list) tab-width)))
+   (or (indent-next-tab-stop 0))))
 
 (defun asm-colon ()
   "Insert a colon; if it follows a label, delete the label's indentation."

=== modified file 'lisp/progmodes/sh-script.el'
--- a/lisp/progmodes/sh-script.el       2014-06-21 19:45:59 +0000
+++ b/lisp/progmodes/sh-script.el       2014-06-26 06:55:15 +0000
@@ -481,6 +481,9 @@
        ?~ "_"
        ?, "_"
        ?= "."
+       ?\; "."
+       ?| "."
+       ?& "."
        ?< "."
        ?> ".")
   "The syntax table to use for Shell-Script mode.
@@ -1860,6 +1863,40 @@
    ((equal tok "in") (sh-smie--sh-keyword-in-p))
    (t (sh-smie--keyword-p))))
 
+(defun sh-smie--default-forward-token ()
+  (forward-comment (point-max))
+  (buffer-substring-no-properties
+   (point)
+   (progn (if (zerop (skip-syntax-forward "."))
+              (while (progn (skip-syntax-forward "w_'")
+                            (looking-at "\\\\"))
+                (forward-char 2)))
+          (point))))
+
+(defun sh-smie--default-backward-token ()
+  (forward-comment (- (point)))
+  (let ((pos (point))
+        (n (skip-syntax-backward ".")))
+    (if (or (zerop n)
+            (and (eq n -1)
+                 (let ((p (point)))
+                   (if (eq -1 (% (skip-syntax-backward "\\") 2))
+                       t
+                     (goto-char p)
+                     nil))))
+        (while
+            (progn (skip-syntax-backward "w_'")
+                   (or (not (zerop (skip-syntax-backward "\\")))
+                       (when (eq ?\\ (char-before (1- (point))))
+                         (let ((p (point)))
+                           (forward-char -1)
+                           (if (eq -1 (% (skip-syntax-backward "\\") 2))
+                               t
+                             (goto-char p)
+                             nil))))))
+      (goto-char (- (point) (% (skip-syntax-backward "\\") 2))))
+    (buffer-substring-no-properties (point) pos)))
+
 (defun sh-smie-sh-forward-token ()
   (if (and (looking-at "[ \t]*\\(?:#\\|\\(\\s|\\)\\|$\\)")
            (save-excursion
@@ -1888,7 +1925,7 @@
         tok))
      (t
       (let* ((pos (point))
-             (tok (smie-default-forward-token)))
+             (tok (sh-smie--default-forward-token)))
         (cond
          ((equal tok ")") "case-)")
          ((equal tok "(") "case-(")
@@ -1932,7 +1969,7 @@
       (goto-char (match-beginning 1))
       (match-string-no-properties 1))
      (t
-      (let ((tok (smie-default-backward-token)))
+      (let ((tok (sh-smie--default-backward-token)))
         (cond
          ((equal tok ")") "case-)")
          ((equal tok "(") "case-(")
@@ -1962,18 +1999,18 @@
     (`(:after . "case-)") (- (sh-var-value 'sh-indent-for-case-alt)
                              (sh-var-value 'sh-indent-for-case-label)))
     ((and `(:before . ,_)
-          (guard (when sh-indent-after-continuation
-                   (save-excursion
-                     (ignore-errors
-                       (skip-chars-backward " \t")
-                       (sh-smie--looking-back-at-continuation-p))))))
-     ;; After a line-continuation, make sure the rest is indented.
-     (let* ((sh-indent-after-continuation nil)
-            (indent (smie-indent-calculate))
-            (initial (sh-smie--continuation-start-indent)))
-       (when (and (numberp indent) (numberp initial)
-                  (<= indent initial))
-         `(column . ,(+ initial sh-indentation)))))
+          ;; After a line-continuation, make sure the rest is indented.
+          (guard sh-indent-after-continuation)
+          (guard (save-excursion
+                   (ignore-errors
+                     (skip-chars-backward " \t")
+                     (sh-smie--looking-back-at-continuation-p))))
+          (let initial (sh-smie--continuation-start-indent))
+          (guard (let* ((sh-indent-after-continuation nil)
+                        (indent (smie-indent-calculate)))
+                   (and (numberp indent) (numberp initial)
+                        (<= indent initial)))))
+     `(column . ,(+ initial sh-indentation)))
     (`(:before . ,(or `"(" `"{" `"["))
      (when (smie-rule-hanging-p)
        (if (not (smie-rule-prev-p "&&" "||" "|"))
@@ -1997,7 +2034,12 @@
                             (smie-rule-bolp))))
                  (current-column)
                (smie-indent-calculate)))))
-    (`(:after . ,(or `"|" `"&&" `"||")) (if (smie-rule-parent-p token) nil 4))
+    (`(:before . ,(or `"|" `"&&" `"||"))
+     (unless (smie-rule-parent-p token)
+       (smie-backward-sexp token)
+       `(column . ,(+ (funcall smie-rules-function :elem 'basic)
+                      (smie-indent-virtual)))))
+
     ;; Attempt at backward compatibility with the old config variables.
     (`(:before . "fi") (sh-var-value 'sh-indent-for-fi))
     (`(:before . "done") (sh-var-value 'sh-indent-for-done))
@@ -2118,7 +2160,7 @@
      ;;    tok))
      (t
       (let* ((pos (point))
-             (tok (smie-default-forward-token)))
+             (tok (sh-smie--default-forward-token)))
         (cond
          ;; ((equal tok ")") "case-)")
          ((and tok (string-match "\\`[a-z]" tok)
@@ -2159,7 +2201,7 @@
      ;;  (goto-char (match-beginning 1))
      ;;  (match-string-no-properties 1))
      (t
-      (let ((tok (smie-default-backward-token)))
+      (let ((tok (sh-smie--default-backward-token)))
         (cond
          ;; ((equal tok ")") "case-)")
          ((and tok (string-match "\\`[a-z]" tok)

=== modified file 'lisp/ruler-mode.el'
--- a/lisp/ruler-mode.el        2014-06-16 06:37:37 +0000
+++ b/lisp/ruler-mode.el        2014-06-26 06:55:15 +0000
@@ -476,8 +476,9 @@
                (not (member ts tab-stop-list))
                (progn
                  (message "Tab stop set to %d" ts)
-                 (setq tab-stop-list (sort (cons ts tab-stop-list)
-                                           #'<)))))))))
+                 (when (null tab-stop-list)
+                   (setq tab-stop-list (indent-accumulate-tab-stops (1- ts))))
+                 (setq tab-stop-list (sort (cons ts tab-stop-list) #'<)))))))))
 
 (defun ruler-mode-mouse-del-tab-stop (start-event)
   "Delete tab stop at the graduation where the mouse pointer is on.
@@ -753,7 +754,7 @@
          i (1+ i) 'help-echo ruler-mode-fill-column-help-echo
          ruler))
        ;; Show the `tab-stop-list' markers.
-       ((and ruler-mode-show-tab-stops (member j tab-stop-list))
+       ((and ruler-mode-show-tab-stops (= j (indent-next-tab-stop (1- j))))
         (aset ruler i ruler-mode-tab-stop-char)
         (put-text-property
          i (1+ i) 'face 'ruler-mode-tab-stop

=== modified file 'lisp/textmodes/picture.el'
--- a/lisp/textmodes/picture.el 2014-02-10 01:34:22 +0000
+++ b/lisp/textmodes/picture.el 2014-06-25 23:53:37 +0000
@@ -418,7 +418,8 @@
   (save-excursion
     (let (tabs)
       (if arg
-         (setq tabs (default-value 'tab-stop-list))
+         (setq tabs (or (default-value 'tab-stop-list)
+                        (indent-accumulate-tab-stops (window-width))))
        (let ((regexp (concat "[ \t]+[" (regexp-quote picture-tab-chars) "]")))
          (beginning-of-line)
          (let ((bol (point)))

=== modified file 'lisp/url/ChangeLog'
--- a/lisp/url/ChangeLog        2014-05-14 17:15:15 +0000
+++ b/lisp/url/ChangeLog        2014-06-26 06:55:15 +0000
@@ -1,3 +1,11 @@
+2014-06-26  Leo Liu  <address@hidden>
+
+       * url-http.el (url-http-end-of-headers): Remove duplicate defvar.
+
+       * url-handlers.el (url-http-parse-response): Remove unused autoload.
+       (url-insert-file-contents): Condition on url-http-response-status
+       for the HTTP/S specific part.  (Bug#17549)
+
 2014-05-14  Glenn Morris  <address@hidden>
 
        * url-util.el (url-make-private-file): Use with-file-modes.

=== modified file 'lisp/url/url-handlers.el'
--- a/lisp/url/url-handlers.el  2014-05-12 06:59:30 +0000
+++ b/lisp/url/url-handlers.el  2014-06-26 06:55:15 +0000
@@ -33,7 +33,6 @@
 (autoload 'url-expand-file-name "url-expand" "Convert url to a fully specified 
url, and canonicalize it.")
 (autoload 'mm-dissect-buffer "mm-decode" "Dissect the current buffer and 
return a list of MIME handles.")
 (autoload 'url-scheme-get-property "url-methods" "Get property of a URL 
SCHEME.")
-(autoload 'url-http-parse-response "url-http" "Parse just the response code.")
 
 ;; Always used after mm-dissect-buffer and defined in the same file.
 (declare-function mm-save-part-to-file "mm-decode" (handle file))
@@ -308,17 +307,21 @@
       (insert data))
     (list (length data) charset)))
 
+(defvar url-http-codes)
+
 ;;;###autoload
 (defun url-insert-file-contents (url &optional visit beg end replace)
   (let ((buffer (url-retrieve-synchronously url)))
     (unless buffer (signal 'file-error (list url "No Data")))
     (with-current-buffer buffer
-      (let ((response (url-http-parse-response)))
-        (if (and (>= response 200) (< response 300))
-            (goto-char (point-min))
-          (let ((desc (buffer-substring-no-properties (1+ (point))
-                                                      (line-end-position))))
+      ;; XXX: This is HTTP/S specific and should be moved to url-http
+      ;; instead.  See http://debbugs.gnu.org/17549.
+      (when (bound-and-true-p url-http-response-status)
+        (unless (and (>= url-http-response-status 200)
+                     (< url-http-response-status 300))
+          (let ((desc (nth 2 (assq url-http-response-status url-http-codes))))
             (kill-buffer buffer)
+            ;; Signal file-error per http://debbugs.gnu.org/16733.
             (signal 'file-error (list url desc))))))
     (if visit (setq buffer-file-name url))
     (save-excursion
@@ -333,6 +336,7 @@
           ;; usual heuristic/rules that we apply to files.
           (decode-coding-inserted-region start (point) url visit beg end 
replace))
         (list url (car size-and-charset))))))
+
 (put 'insert-file-contents 'url-file-handlers 'url-insert-file-contents)
 
 (defun url-file-name-completion (url directory &optional predicate)

=== modified file 'lisp/url/url-http.el'
--- a/lisp/url/url-http.el      2014-03-29 00:55:44 +0000
+++ b/lisp/url/url-http.el      2014-06-26 06:55:15 +0000
@@ -48,7 +48,6 @@
 (defvar url-http-response-version)
 (defvar url-http-target-url)
 (defvar url-http-transfer-encoding)
-(defvar url-http-end-of-headers)
 (defvar url-show-status)
 
 (require 'url-gw)

=== modified file 'test/ChangeLog'
--- a/test/ChangeLog    2014-06-26 06:02:52 +0000
+++ b/test/ChangeLog    2014-06-26 06:55:15 +0000
@@ -1,3 +1,9 @@
+2014-06-26  Stefan Monnier  <address@hidden>
+
+       * automated/package-test.el (package-test-update-listing)
+       (package-test-update-archives, package-test-describe-package):
+       Adjust tests according to new package-list-unsigned.
+
 2014-06-26  Glenn Morris  <address@hidden>
 
        * automated/ert-tests.el (no-byte-compile): Set it.  (Bug#17851)

=== modified file 'test/automated/package-test.el'
--- a/test/automated/package-test.el    2014-05-26 16:52:28 +0000
+++ b/test/automated/package-test.el    2014-06-26 06:55:15 +0000
@@ -265,7 +265,7 @@
       (should (package-installed-p 'simple-single))
       (switch-to-buffer "*Packages*")
       (goto-char (point-min))
-      (should (re-search-forward "^\\s-+simple-single\\s-+1.3\\s-+unsigned" 
nil t))
+      (should (re-search-forward "^\\s-+simple-single\\s-+1.3\\s-+installed" 
nil t))
       (goto-char (point-min))
       (should-not (re-search-forward 
"^\\s-+simple-single\\s-+1.3\\s-+\\(available\\|new\\)" nil t))
       (kill-buffer buf))))
@@ -287,7 +287,7 @@
         ;; New version should be available and old version should be installed
         (goto-char (point-min))
         (should (re-search-forward "^\\s-+simple-single\\s-+1.4\\s-+new" nil 
t))
-        (should (re-search-forward "^\\s-+simple-single\\s-+1.3\\s-+unsigned" 
nil t))
+        (should (re-search-forward "^\\s-+simple-single\\s-+1.3\\s-+installed" 
nil t))
 
         (goto-char (point-min))
         (should (re-search-forward 
"^\\s-+new-pkg\\s-+1.0\\s-+\\(available\\|new\\)" nil t))
@@ -318,7 +318,7 @@
     (with-fake-help-buffer
      (describe-package 'simple-single)
      (goto-char (point-min))
-     (should (search-forward "simple-single is an unsigned package." nil t))
+     (should (search-forward "simple-single is an installed package." nil t))
      (should (search-forward
               (format "Status: Installed in `%s/' (unsigned)."
                       (expand-file-name "simple-single-1.3" package-user-dir))

=== modified file 'test/indent/shell.sh'
--- a/test/indent/shell.sh      2014-06-20 14:23:30 +0000
+++ b/test/indent/shell.sh      2014-06-24 20:16:10 +0000
@@ -41,6 +41,13 @@
     }
 done
 
+filter_3 ()                     # bug#17842
+{
+    tr -d '"`' | tr '  ' ' ' | \
+        awk -F\; -f filter.awk | \
+       grep -v "^," | sort -t, -k2,2
+}
+
 echo -n $(( 5 << 2 ))
 # This should not be treated as a heredoc (bug#12770).
 2


reply via email to

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