------------------------------------------------------------ revno: 115561 committer: Stefan Monnier branch nick: trunk timestamp: Mon 2013-12-16 21:48:06 -0500 message: * lisp/net/shr.el (shr-insert-document): Remove unused var `shr-preliminary-table-render'. (shr-rescale-image): Remove unused arg `force'. (shr-put-image): Update calls accordingly. (shr-tag-a): Use `cont' rather than dyn-bound `dom'. diff: === modified file 'lisp/ChangeLog' --- lisp/ChangeLog 2013-12-17 01:31:55 +0000 +++ lisp/ChangeLog 2013-12-17 02:48:06 +0000 @@ -1,3 +1,11 @@ +2013-12-17 Stefan Monnier + + * net/shr.el (shr-insert-document): Remove unused var + `shr-preliminary-table-render'. + (shr-rescale-image): Remove unused arg `force'. + (shr-put-image): Update calls accordingly. + (shr-tag-a): Use `cont' rather than dyn-bound `dom'. + 2013-12-17 Dmitry Gutov * emacs-lisp/smie.el (smie-indent--rule): Extract `smie-indent--rule-1'. === modified file 'lisp/net/shr.el' --- lisp/net/shr.el 2013-12-16 23:40:17 +0000 +++ lisp/net/shr.el 2013-12-17 02:48:06 +0000 @@ -196,7 +196,6 @@ (shr-state nil) (shr-start nil) (shr-base nil) - (shr-preliminary-table-render 0) (shr-width (or shr-width (1- (window-width))))) (shr-descend (shr-transform-dom dom)) (shr-remove-trailing-whitespace start (point)))) @@ -380,8 +379,7 @@ (setq shr-stylesheet (nconc (shr-parse-style style) shr-stylesheet)) (setq style nil))) - ;; If we have a display:none, then just ignore this part of the - ;; DOM. + ;; If we have a display:none, then just ignore this part of the DOM. (unless (equal (cdr (assq 'display shr-stylesheet)) "none") (if (fboundp function) (funcall function (cdr dom)) @@ -754,10 +752,10 @@ :format content-type)) ((eq size 'full) (ignore-errors - (shr-rescale-image data t content-type))) + (shr-rescale-image data content-type))) (t (ignore-errors - (shr-rescale-image data nil content-type)))))) + (shr-rescale-image data content-type)))))) (when image ;; When inserting big-ish pictures, put them at the ;; beginning of the line. @@ -779,11 +777,10 @@ image) (insert alt))) -(defun shr-rescale-image (data &optional force content-type) - "Rescale DATA, if too big, to fit the current buffer. -If FORCE, rescale the image anyway." - (if (or (not (fboundp 'imagemagick-types)) - (not (get-buffer-window (current-buffer)))) +(defun shr-rescale-image (data &optional content-type) + "Rescale DATA, if too big, to fit the current buffer." + (if (not (and (fboundp 'imagemagick-types) + (get-buffer-window (current-buffer)))) (create-image data nil t :ascent 100) (let ((edges (window-inside-pixel-edges (get-buffer-window (current-buffer))))) @@ -964,13 +961,13 @@ (shr-generic cont) (shr-colorize-region start (point) fgcolor bgcolor))) -(defun shr-tag-style (cont) - ) - -(defun shr-tag-script (cont) - ) - -(defun shr-tag-comment (cont) +(defun shr-tag-style (_cont) + ) + +(defun shr-tag-script (_cont) + ) + +(defun shr-tag-comment (_cont) ) (defun shr-dom-to-xml (dom) @@ -1079,7 +1076,7 @@ shr-start) (shr-generic cont) (when (and shr-target-id - (equal (cdr (assq :name (cdr dom))) shr-target-id)) + (equal (cdr (assq :name cont)) shr-target-id)) ;; We have a zero-length element, so just ;; insert... something. (when (= start (point)) @@ -1326,7 +1323,7 @@ (defun shr-tag-h6 (cont) (shr-heading cont)) -(defun shr-tag-hr (cont) +(defun shr-tag-hr (_cont) (shr-ensure-newline) (insert (make-string shr-width shr-hr-line) "\n")) ------------------------------------------------------------ revno: 115560 fixes bug: http://debbugs.gnu.org/16116 committer: Dmitry Gutov branch nick: trunk timestamp: Tue 2013-12-17 03:31:55 +0200 message: Fix bug#16116 * lisp/emacs-lisp/smie.el (smie-indent--rule): Extract `smie-indent--rule-1'. (smie-indent-close): Call `smie-indent--rule-1' with METHOD :close-all, to see which indentation method to use. (smie-rules-function): Document the method :close-all. * test/indent/ruby.rb: Update examples according to the change in `smie-indent-close'. diff: === modified file 'lisp/ChangeLog' --- lisp/ChangeLog 2013-12-16 23:40:17 +0000 +++ lisp/ChangeLog 2013-12-17 01:31:55 +0000 @@ -1,3 +1,10 @@ +2013-12-17 Dmitry Gutov + + * emacs-lisp/smie.el (smie-indent--rule): Extract `smie-indent--rule-1'. + (smie-indent-close): Call `smie-indent--rule-1' with METHOD + :close-all, to see which indentation method to use (Bug#16116). + (smie-rules-function): Document the method :close-all. + 2013-12-16 Lars Magne Ingebrigtsen * net/shr.el (shr-tag-a): Support zero-length elements. === modified file 'lisp/emacs-lisp/smie.el' --- lisp/emacs-lisp/smie.el 2013-12-11 15:59:27 +0000 +++ lisp/emacs-lisp/smie.el 2013-12-17 01:31:55 +0000 @@ -1135,6 +1135,10 @@ - :list-intro, in which case ARG is a token and the function should return non-nil if TOKEN is followed by a list of expressions (not separated by any token) rather than an expression. +- :close-all, in which case ARG is a close-paren token at indentation and + the function should return non-nil if it should be aligned with the opener + of the last close-paren token on the same line, if there are multiple. + Otherwise, it will be aligned with its own opener. When ARG is a token, the function is called with point just before that token. A return value of nil always means to fallback on the default behavior, so the @@ -1316,8 +1320,8 @@ (defun smie-indent--rule (method token ;; FIXME: Too many parameters. &optional after parent base-pos) - "Compute indentation column according to `indent-rule-functions'. -METHOD and TOKEN are passed to `indent-rule-functions'. + "Compute indentation column according to `smie-rules-function'. +METHOD and TOKEN are passed to `smie-rules-function'. AFTER is the position after TOKEN, if known. PARENT is the parent info returned by `smie-backward-sexp', if known. BASE-POS is the position relative to which offsets should be applied." @@ -1330,11 +1334,7 @@ ;; - :after tok, where ;; ; after is set; parent=nil; base-pos=point; (save-excursion - (let ((offset - (let ((smie--parent parent) - (smie--token token) - (smie--after after)) - (funcall smie-rules-function method token)))) + (let ((offset (smie-indent--rule-1 method token after parent))) (cond ((not offset) nil) ((eq (car-safe offset) 'column) (cdr offset)) @@ -1355,6 +1355,12 @@ (smie-indent-virtual) (current-column))))) (t (error "Unknown indentation offset %s" offset)))))) +(defun smie-indent--rule-1 (method token &optional after parent) + (let ((smie--parent parent) + (smie--token token) + (smie--after after)) + (funcall smie-rules-function method token))) + (defun smie-indent-forward-token () "Skip token forward and return it, along with its levels." (let ((tok (funcall smie-forward-token-function))) @@ -1423,8 +1429,13 @@ (save-excursion ;; (forward-comment (point-max)) (when (looking-at "\\s)") - (while (not (zerop (skip-syntax-forward ")"))) - (skip-chars-forward " \t")) + (if (smie-indent--rule-1 :close-all + (buffer-substring-no-properties + (point) (1+ (point))) + (1+ (point))) + (while (not (zerop (skip-syntax-forward ")"))) + (skip-chars-forward " \t")) + (forward-char 1)) (condition-case nil (progn (backward-sexp 1) === modified file 'test/ChangeLog' --- test/ChangeLog 2013-12-14 06:46:13 +0000 +++ test/ChangeLog 2013-12-17 01:31:55 +0000 @@ -1,3 +1,8 @@ +2013-12-17 Dmitry Gutov + + * indent/ruby.rb: Update examples according to the change + in `smie-indent-close'. + 2013-12-14 Dmitry Gutov * indent/ruby.rb: New examples. === modified file 'test/indent/ruby.rb' --- test/indent/ruby.rb 2013-12-14 06:46:13 +0000 +++ test/indent/ruby.rb 2013-12-17 01:31:55 +0000 @@ -48,8 +48,7 @@ foo({ # bug#16118 a: b, c: d - } - ) # bug#16116 + }) bar = foo( a, [ @@ -57,8 +56,7 @@ ], :qux => [ 3 - ] - ) + ]) foo( [ @@ -78,8 +76,7 @@ b: 3 }, 4 - ] - ) + ]) foo = [ # ruby-deep-indent-disabled 1 ------------------------------------------------------------ revno: 115559 committer: Lars Magne Ingebrigtsen branch nick: trunk timestamp: Tue 2013-12-17 00:40:17 +0100 message: * net/shr.el (shr-tag-a): Support zero-length elements. diff: === modified file 'lisp/ChangeLog' --- lisp/ChangeLog 2013-12-16 23:29:47 +0000 +++ lisp/ChangeLog 2013-12-16 23:40:17 +0000 @@ -1,5 +1,7 @@ 2013-12-16 Lars Magne Ingebrigtsen + * net/shr.el (shr-tag-a): Support zero-length elements. + * net/eww.el (eww-display-html): If we can't find the anchor we're looking for, then go to point-min. === modified file 'lisp/net/eww.el' --- lisp/net/eww.el 2013-12-16 23:29:47 +0000 +++ lisp/net/eww.el 2013-12-16 23:40:17 +0000 @@ -269,11 +269,11 @@ (point (goto-char point)) (shr-target-id + (goto-char (point-min)) (let ((point (next-single-property-change (point-min) 'shr-target-id))) - (goto-char (if point - (1+ point) - (point-min))))) + (when point + (goto-char point)))) (t (goto-char (point-min))))) (setq eww-current-url url === modified file 'lisp/net/shr.el' --- lisp/net/shr.el 2013-12-07 01:44:15 +0000 +++ lisp/net/shr.el 2013-12-16 23:40:17 +0000 @@ -1078,6 +1078,14 @@ (start (point)) shr-start) (shr-generic cont) + (when (and shr-target-id + (equal (cdr (assq :name (cdr dom))) shr-target-id)) + ;; We have a zero-length element, so just + ;; insert... something. + (when (= start (point)) + (shr-ensure-newline) + (insert " ")) + (put-text-property start (1+ start) 'shr-target-id shr-target-id)) (when (and url (not shr-inhibit-decoration)) (shr-urlify (or shr-start start) (shr-expand-url url) title)))) ------------------------------------------------------------ revno: 115558 committer: Lars Magne Ingebrigtsen branch nick: trunk timestamp: Tue 2013-12-17 00:29:47 +0100 message: eww anchor pointer movement fixup * net/eww.el (eww-display-html): If we can't find the anchor we're looking for, then go to point-min. diff: === modified file 'lisp/ChangeLog' --- lisp/ChangeLog 2013-12-16 22:35:57 +0000 +++ lisp/ChangeLog 2013-12-16 23:29:47 +0000 @@ -1,3 +1,8 @@ +2013-12-16 Lars Magne Ingebrigtsen + + * net/eww.el (eww-display-html): If we can't find the anchor we're + looking for, then go to point-min. + 2013-12-16 Paul Eggert Fix problems with CANNOT_DUMP and EMACSLOADPATH. === modified file 'lisp/net/eww.el' --- lisp/net/eww.el 2013-12-11 19:01:44 +0000 +++ lisp/net/eww.el 2013-12-16 23:29:47 +0000 @@ -271,8 +271,9 @@ (shr-target-id (let ((point (next-single-property-change (point-min) 'shr-target-id))) - (when point - (goto-char (1+ point))))) + (goto-char (if point + (1+ point) + (point-min))))) (t (goto-char (point-min))))) (setq eww-current-url url ------------------------------------------------------------ revno: 115557 committer: Paul Eggert branch nick: trunk timestamp: Mon 2013-12-16 14:35:57 -0800 message: Fix problems with CANNOT_DUMP and EMACSLOADPATH. * leim/Makefile.in (RUN_EMACS): * lisp/Makefile.in (emacs): Add lisp src to EMACSLOADPATH. * lisp/loadup.el: Check for src/bootstrap-emacs only when Emacs can dump. Expand dir too, in case it's relative. * src/lread.c (init_lread): If CANNOT_DUMP, we can't be dumping. diff: === modified file 'leim/ChangeLog' --- leim/ChangeLog 2013-11-28 20:31:55 +0000 +++ leim/ChangeLog 2013-12-16 22:35:57 +0000 @@ -1,3 +1,8 @@ +2013-12-16 Paul Eggert + + Fix problems with CANNOT_DUMP and EMACSLOADPATH. + * Makefile.in (RUN_EMACS): Add lisp src to EMACSLOADPATH. + 2013-11-28 Glenn Morris * Makefile.in (${leimdir}/leim-list.el): === modified file 'leim/Makefile.in' --- leim/Makefile.in 2013-11-28 23:34:15 +0000 +++ leim/Makefile.in 2013-12-16 22:35:57 +0000 @@ -34,8 +34,8 @@ EMACS = ../src/emacs # How to run Emacs. -# Prevent any setting of EMACSLOADPATH in user environment causing problems. -RUN_EMACS = EMACSLOADPATH= "${EMACS}" -batch --no-site-file --no-site-lisp +RUN_EMACS = EMACSLOADPATH='$(srcdir)/../lisp' '$(EMACS)' \ + -batch --no-site-file --no-site-lisp MKDIR_P = @MKDIR_P@ === modified file 'lisp/ChangeLog' --- lisp/ChangeLog 2013-12-16 21:48:51 +0000 +++ lisp/ChangeLog 2013-12-16 22:35:57 +0000 @@ -1,3 +1,10 @@ +2013-12-16 Paul Eggert + + Fix problems with CANNOT_DUMP and EMACSLOADPATH. + * Makefile.in (emacs): Add lisp src to EMACSLOADPATH. + * loadup.el: Check for src/bootstrap-emacs only when Emacs can dump. + Expand dir too, in case it's relative. + 2013-12-16 Juri Linkov * desktop.el (desktop-auto-save-timeout): Change default to === modified file 'lisp/Makefile.in' --- lisp/Makefile.in 2013-12-11 17:05:28 +0000 +++ lisp/Makefile.in 2013-12-16 22:35:57 +0000 @@ -105,8 +105,7 @@ $(lisp)/emacs-lisp/autoload.elc # The actual Emacs command run in the targets below. -# Prevent any setting of EMACSLOADPATH in user environment causing problems. -emacs = EMACSLOADPATH= "$(EMACS)" $(EMACSOPT) +emacs = EMACSLOADPATH='$(lisp)' '$(EMACS)' $(EMACSOPT) # Common command to find subdirectories setwins=for file in `find . -type d -print`; do \ === modified file 'lisp/loadup.el' --- lisp/loadup.el 2013-12-13 18:25:30 +0000 +++ lisp/loadup.el 2013-12-16 22:35:57 +0000 @@ -51,12 +51,13 @@ ;; FIXME this is irritatingly fragile. (equal (nth 4 command-line-args) "unidata-gen.el") (equal (nth 7 command-line-args) "unidata-gen-files") - ;; In case CANNOT_DUMP. - (string-match "src/bootstrap-emacs" (nth 0 command-line-args))) + (if (fboundp 'dump-emacs) + (string-match "src/bootstrap-emacs" (nth 0 command-line-args)) + t)) (let ((dir (car load-path))) ;; We'll probably overflow the pure space. (setq purify-flag nil) - (setq load-path (list dir + (setq load-path (list (expand-file-name "." dir) (expand-file-name "emacs-lisp" dir) (expand-file-name "language" dir) (expand-file-name "international" dir) === modified file 'src/ChangeLog' --- src/ChangeLog 2013-12-16 19:29:04 +0000 +++ src/ChangeLog 2013-12-16 22:35:57 +0000 @@ -1,3 +1,8 @@ +2013-12-16 Paul Eggert + + Fix problems with CANNOT_DUMP and EMACSLOADPATH. + * lread.c (init_lread): If CANNOT_DUMP, we can't be dumping. + 2013-12-16 Eli Zaretskii * xdisp.c (Fmove_point_visually): Fix subtle bugs in the fallback === modified file 'src/lread.c' --- src/lread.c 2013-12-13 22:27:05 +0000 +++ src/lread.c 2013-12-16 22:35:57 +0000 @@ -4293,8 +4293,14 @@ { /* First, set Vload_path. */ - /* We explicitly ignore EMACSLOADPATH when dumping. */ - if (NILP (Vpurify_flag) && egetenv ("EMACSLOADPATH")) + /* Ignore EMACSLOADPATH when dumping. */ +#ifdef CANNOT_DUMP + bool use_loadpath = true; +#else + bool use_loadpath = !NILP (Vpurify_flag); +#endif + + if (use_loadpath && egetenv ("EMACSLOADPATH")) { Vload_path = decode_env_path ("EMACSLOADPATH", 0, 1); ------------------------------------------------------------ revno: 115556 fixes bug: http://debbugs.gnu.org/15331 committer: Juri Linkov branch nick: trunk timestamp: Mon 2013-12-16 23:48:51 +0200 message: * lisp/desktop.el (desktop-auto-save-timeout): Change default to `auto-save-timeout'. Doc fix. (desktop-save): Skip the timestamp in desktop-saved-frameset when checking for auto-save changes. (desktop-auto-save): Don't call desktop-auto-save-set-timer since `desktop-auto-save' is called repeatedly by the idle timer. (desktop-auto-save-set-timer): Replace `run-with-timer' with `run-with-idle-timer' and a non-nil arg REPEAT. Doc fix. diff: === modified file 'etc/NEWS' --- etc/NEWS 2013-12-16 02:24:08 +0000 +++ etc/NEWS 2013-12-16 21:48:51 +0000 @@ -398,8 +398,8 @@ ** Desktop -*** `desktop-auto-save-timeout' defines the number of seconds between -auto-saves of the desktop. +*** `desktop-auto-save-timeout' defines the number of seconds idle time +before auto-save of the desktop. *** `desktop-restore-frames', enabled by default, allows saving and restoring the frame/window configuration (frameset). Additional options === modified file 'lisp/ChangeLog' --- lisp/ChangeLog 2013-12-16 20:32:15 +0000 +++ lisp/ChangeLog 2013-12-16 21:48:51 +0000 @@ -1,5 +1,17 @@ 2013-12-16 Juri Linkov + * desktop.el (desktop-auto-save-timeout): Change default to + `auto-save-timeout'. Doc fix. + (desktop-save): Skip the timestamp in desktop-saved-frameset + when checking for auto-save changes. + (desktop-auto-save): Don't call desktop-auto-save-set-timer since + `desktop-auto-save' is called repeatedly by the idle timer. + (desktop-auto-save-set-timer): Replace `run-with-timer' with + `run-with-idle-timer' and a non-nil arg REPEAT. Doc fix. + (Bug#15331) + +2013-12-16 Juri Linkov + * isearch.el (isearch-mode-map): Remove [escape] key bindinds. (Bug#16035) (isearch-pre-command-hook): Check `this-command' for symbolp. === modified file 'lisp/desktop.el' --- lisp/desktop.el 2013-10-13 00:31:19 +0000 +++ lisp/desktop.el 2013-12-16 21:48:51 +0000 @@ -191,9 +191,9 @@ :group 'desktop :version "22.1") -(defcustom desktop-auto-save-timeout nil - "Number of seconds between auto-saves of the desktop. -Zero or nil means disable timer-based auto-saving." +(defcustom desktop-auto-save-timeout auto-save-timeout + "Number of seconds idle time before auto-save of the desktop. +Zero or nil means disable auto-saving due to idleness." :type '(choice (const :tag "Off" nil) (integer :tag "Seconds")) :set (lambda (symbol value) @@ -992,12 +992,21 @@ (insert ")\n\n")))) (setq default-directory desktop-dirname) - ;; If auto-saving, avoid writing if nothing has changed since the last write. - ;; Don't check 300 characters of the header that contains the timestamp. - (let ((checksum (and auto-save (md5 (current-buffer) - (+ (point-min) 300) (point-max) - 'emacs-mule)))) - (unless (and auto-save (equal checksum desktop-file-checksum)) + ;; When auto-saving, avoid writing if nothing has changed since the last write. + (let* ((beg (and auto-save + (save-excursion + (goto-char (point-min)) + ;; Don't check the header with changing timestamp + (and (search-forward "Global section" nil t) + ;; Also skip the timestamp in desktop-saved-frameset + ;; if it's saved in the first non-header line + (search-forward "desktop-saved-frameset" + (line-beginning-position 3) t) + ;; This is saved after the timestamp + (search-forward (format "%S" desktop--app-id) nil t)) + (point)))) + (checksum (and beg (md5 (current-buffer) beg (point-max) 'emacs-mule)))) + (unless (and checksum (equal checksum desktop-file-checksum)) (let ((coding-system-for-write 'emacs-mule)) (write-region (point-min) (point-max) (desktop-full-file-name) nil 'nomessage)) (setq desktop-file-checksum checksum) @@ -1199,21 +1208,21 @@ ;; Save only to own desktop file. (eq (emacs-pid) (desktop-owner)) desktop-dirname) - (desktop-save desktop-dirname nil t)) - (desktop-auto-save-set-timer)) + (desktop-save desktop-dirname nil t))) (defun desktop-auto-save-set-timer () - "Reset the auto-save timer. + "Set the auto-save timer. Cancel any previous timer. When `desktop-auto-save-timeout' is a positive -integer, start a new timer to call `desktop-auto-save' in that many seconds." +integer, start a new idle timer to call `desktop-auto-save' repeatedly +after that many seconds of idle time." (when desktop-auto-save-timer (cancel-timer desktop-auto-save-timer) (setq desktop-auto-save-timer nil)) (when (and (integerp desktop-auto-save-timeout) (> desktop-auto-save-timeout 0)) (setq desktop-auto-save-timer - (run-with-timer desktop-auto-save-timeout nil - 'desktop-auto-save)))) + (run-with-idle-timer desktop-auto-save-timeout t + 'desktop-auto-save)))) ;; ---------------------------------------------------------------------------- ;;;###autoload ------------------------------------------------------------ revno: 115555 fixes bug: http://debbugs.gnu.org/16035 committer: Juri Linkov branch nick: trunk timestamp: Mon 2013-12-16 22:32:15 +0200 message: * lisp/isearch.el (isearch-mode-map): Remove [escape] key bindinds. (isearch-pre-command-hook): Check `this-command' for symbolp. diff: === modified file 'lisp/ChangeLog' --- lisp/ChangeLog 2013-12-16 19:12:21 +0000 +++ lisp/ChangeLog 2013-12-16 20:32:15 +0000 @@ -1,3 +1,9 @@ +2013-12-16 Juri Linkov + + * isearch.el (isearch-mode-map): Remove [escape] key bindinds. + (Bug#16035) + (isearch-pre-command-hook): Check `this-command' for symbolp. + 2013-12-16 Stefan Monnier * emacs-lisp/gv.el (gv-ref): Mention lexbind restriction (bug#16153). === modified file 'lisp/isearch.el' --- lisp/isearch.el 2013-12-06 00:55:20 +0000 +++ lisp/isearch.el 2013-12-16 20:32:15 +0000 @@ -435,8 +435,7 @@ ;; would be simpler to disable the global keymap, and/or have a ;; default local key binding for any key not otherwise bound. (let ((meta-map (make-sparse-keymap))) - (define-key map (char-to-string meta-prefix-char) meta-map) - (define-key map [escape] meta-map)) + (define-key map (char-to-string meta-prefix-char) meta-map)) ;; Several non-printing chars change the searching behavior. (define-key map "\C-s" 'isearch-repeat-forward) @@ -453,7 +452,6 @@ (or (= ?\e meta-prefix-char) (error "Inconsistency in isearch.el")) (define-key map "\e\e\e" 'isearch-cancel) - (define-key map [escape escape escape] 'isearch-cancel) (define-key map "\C-q" 'isearch-quote-char) @@ -2251,6 +2249,7 @@ (memq this-command '(universal-argument digit-argument negative-argument))) (and isearch-allow-scroll + (symbolp this-command) (or (eq (get this-command 'isearch-scroll) t) (eq (get this-command 'scroll-command) t)))) (when isearch-allow-scroll ------------------------------------------------------------ revno: 115554 fixes bug: http://debbugs.gnu.org/16165 committer: Eli Zaretskii branch nick: trunk timestamp: Mon 2013-12-16 21:29:04 +0200 message: Fix compilation errors introduced by changes in extend_face_to_end_of_line. src/xdisp.c (extend_face_to_end_of_line): Don't reference tool_bar_window in GTK and NS builds, they don't have this member of struct frame. diff: === modified file 'src/ChangeLog' --- src/ChangeLog 2013-12-16 18:09:36 +0000 +++ src/ChangeLog 2013-12-16 19:29:04 +0000 @@ -3,6 +3,8 @@ * xdisp.c (Fmove_point_visually): Fix subtle bugs in the fallback code, revealed in presence of R2L characters, character compositions, and display vectors. A better fix for Bug#16148. + (extend_face_to_end_of_line): Don't reference tool_bar_window in + GTK and NS builds, they don't have this member of struct frame. * dispextern.h (struct composition_it): Correct a comment for the 'width' member. === modified file 'src/xdisp.c' --- src/xdisp.c 2013-12-16 18:09:36 +0000 +++ src/xdisp.c 2013-12-16 19:29:04 +0000 @@ -18866,8 +18866,11 @@ /* Mode line and the header line don't have margins, and likewise the frame's tool-bar window, if there is any. */ if (!(it->glyph_row->mode_line_p +#if defined (HAVE_WINDOW_SYSTEM) && ! defined (USE_GTK) && ! defined (HAVE_NS) || (WINDOWP (f->tool_bar_window) - && it->w == XWINDOW (f->tool_bar_window)))) + && it->w == XWINDOW (f->tool_bar_window)) +#endif + )) { if (WINDOW_LEFT_MARGIN_WIDTH (it->w) > 0 && it->glyph_row->used[LEFT_MARGIN_AREA] == 0) ------------------------------------------------------------ revno: 115553 fixes bug: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=16153 committer: Stefan Monnier branch nick: trunk timestamp: Mon 2013-12-16 14:12:21 -0500 message: * lisp/emacs-lisp/gv.el (gv-ref): Mention lexbind restriction. diff: === modified file 'lisp/ChangeLog' --- lisp/ChangeLog 2013-12-16 15:49:25 +0000 +++ lisp/ChangeLog 2013-12-16 19:12:21 +0000 @@ -1,3 +1,7 @@ +2013-12-16 Stefan Monnier + + * emacs-lisp/gv.el (gv-ref): Mention lexbind restriction (bug#16153). + 2013-12-16 Teodor Zlatanov * progmodes/cfengine.el (cfengine3--current-word): Remove. @@ -9,8 +13,8 @@ 2013-12-16 Martin Rudalics - * window.el (display-buffer-below-selected): Bind - split-height-threshold to 0 as suggested by Juri Linkov. + * window.el (display-buffer-below-selected): + Bind split-height-threshold to 0 as suggested by Juri Linkov. 2013-12-16 Leo Liu === modified file 'lisp/emacs-lisp/gv.el' --- lisp/emacs-lisp/gv.el 2013-11-06 02:10:18 +0000 +++ lisp/emacs-lisp/gv.el 2013-12-16 19:12:21 +0000 @@ -454,7 +454,10 @@ ;;;###autoload (defmacro gv-ref (place) "Return a reference to PLACE. -This is like the `&' operator of the C language." +This is like the `&' operator of the C language. +Note: this only works reliably with lexical binding mode, except for very +simple PLACEs such as (function-symbol 'foo) which will also work in dynamic +binding mode." (gv-letplace (getter setter) place `(cons (lambda () ,getter) (lambda (gv--val) ,(funcall setter 'gv--val))))) ------------------------------------------------------------ revno: 115552 committer: Eli Zaretskii branch nick: trunk timestamp: Mon 2013-12-16 20:18:44 +0200 message: Update Emacs's Windows manifests to support Windows 8.1. nt/emacs-x64.manifest: nt/emacs-x86.manifest: Declare that we target Windows 8.1 as well as earlier versions. This is so GetVersion and GetVersionEx APIs used for bug reporting and other purposes return accurate version number on Windows 8.1. See the discussion on MSDN http://msdn.microsoft.com/en-us/library/windows/desktop/dn302074.aspx for more details. diff: === modified file 'nt/ChangeLog' --- nt/ChangeLog 2013-12-12 18:19:10 +0000 +++ nt/ChangeLog 2013-12-16 18:18:44 +0000 @@ -1,3 +1,13 @@ +2013-12-16 Eli Zaretskii + + * emacs-x64.manifest: + * emacs-x86.manifest: Declare that we target Windows 8.1 as well + as earlier versions. This is so GetVersion and GetVersionEx APIs + used for bug reporting and other purposes return accurate version + number on Windows 8.1. See the discussion on MSDN + http://msdn.microsoft.com/en-us/library/windows/desktop/dn302074.aspx + for more details. + 2013-12-12 Eli Zaretskii * inc/ms-w32.h (MAX_UTF8_PATH): New macro. === modified file 'nt/emacs-x64.manifest' --- nt/emacs-x64.manifest 2012-09-30 21:36:42 +0000 +++ nt/emacs-x64.manifest 2013-12-16 18:18:44 +0000 @@ -18,4 +18,16 @@ + + + + + + + + + + + + === modified file 'nt/emacs-x86.manifest' --- nt/emacs-x86.manifest 2012-09-30 21:36:42 +0000 +++ nt/emacs-x86.manifest 2013-12-16 18:18:44 +0000 @@ -18,4 +18,16 @@ + + + + + + + + + + + + ------------------------------------------------------------ revno: 115551 fixes bug: http://debbugs.gnu.org/16148 committer: Eli Zaretskii branch nick: trunk timestamp: Mon 2013-12-16 20:09:36 +0200 message: A better fix for bug #16148 and related issues. src/xdisp.c (Fmove_point_visually): Fix subtle bugs in the fallback code, revealed in presence of R2L characters, character compositions, and display vectors. src/dispextern.h (struct composition_it): Correct a comment for the 'width' member. diff: === modified file 'src/ChangeLog' --- src/ChangeLog 2013-12-16 18:05:53 +0000 +++ src/ChangeLog 2013-12-16 18:09:36 +0000 @@ -1,3 +1,12 @@ +2013-12-16 Eli Zaretskii + + * xdisp.c (Fmove_point_visually): Fix subtle bugs in the fallback + code, revealed in presence of R2L characters, character + compositions, and display vectors. A better fix for Bug#16148. + + * dispextern.h (struct composition_it): Correct a comment for the + 'width' member. + 2013-12-16 Paul Eggert * font.h (valid_font_driver) [!ENABLE_CHECKING]: Define a dummy. === modified file 'src/dispextern.h' --- src/dispextern.h 2013-12-15 04:20:53 +0000 +++ src/dispextern.h 2013-12-16 18:09:36 +0000 @@ -2190,9 +2190,8 @@ int nchars, nbytes; /* Indices of the glyphs for the current grapheme cluster. */ int from, to; - /* Width of the current grapheme cluster in units of pixels on a - graphic display and in units of canonical characters on a - terminal display. */ + /* Width of the current grapheme cluster in units of columns it will + occupy on display; see CHAR_WIDTH. */ int width; }; === modified file 'src/xdisp.c' --- src/xdisp.c 2013-12-16 17:59:50 +0000 +++ src/xdisp.c 2013-12-16 18:09:36 +0000 @@ -20589,23 +20589,37 @@ SET_TEXT_POS (pt, PT, PT_BYTE); start_display (&it, w, pt); - if ((it.cmp_it.id < 0 - && it.method == GET_FROM_STRING - && it.area == TEXT_AREA - && it.string_from_display_prop_p - && (it.sp > 0 && it.stack[it.sp - 1].method == GET_FROM_BUFFER)) - || it.method == GET_FROM_DISPLAY_VECTOR) + if (it.cmp_it.id < 0 + && it.method == GET_FROM_STRING + && it.area == TEXT_AREA + && it.string_from_display_prop_p + && (it.sp > 0 && it.stack[it.sp - 1].method == GET_FROM_BUFFER)) overshoot_expected = true; /* Find the X coordinate of point. We start from the beginning of this or previous line to make sure we are before point in the logical order (since the move_it_* functions can only move forward). */ + reseat: reseat_at_previous_visible_line_start (&it); it.current_x = it.hpos = it.current_y = it.vpos = 0; if (IT_CHARPOS (it) != PT) - move_it_to (&it, overshoot_expected ? PT - 1 : PT, - -1, -1, -1, MOVE_TO_POS); + { + move_it_to (&it, overshoot_expected ? PT - 1 : PT, + -1, -1, -1, MOVE_TO_POS); + /* If we missed point because the character there is + displayed out of a display vector that has more than one + glyph, retry expecting overshoot. */ + if (it.method == GET_FROM_DISPLAY_VECTOR + && it.current.dpvec_index > 0 + && !overshoot_expected) + { + overshoot_expected = true; + goto reseat; + } + else if (IT_CHARPOS (it) != PT && !overshoot_expected) + move_it_in_display_line (&it, PT, -1, MOVE_TO_POS); + } pt_x = it.current_x; pt_vpos = it.vpos; if (dir > 0 || overshoot_expected) @@ -20634,9 +20648,9 @@ else if (pixel_width <= 0) pixel_width = 1; - /* If there's a display string at point, we are actually at the - glyph to the left of point, so we need to correct the X - coordinate. */ + /* If there's a display string (or something similar) at point, + we are actually at the glyph to the left of point, so we need + to correct the X coordinate. */ if (overshoot_expected) { if (it.bidi_p) @@ -20699,15 +20713,37 @@ character at point. */ if (FRAME_WINDOW_P (it.f) && dir < 0) { - struct text_pos new_pos = it.current.pos; + struct text_pos new_pos; enum move_it_result rc = MOVE_X_REACHED; + if (it.current_x == 0) + get_next_display_element (&it); + if (it.what == IT_COMPOSITION) + { + new_pos.charpos = it.cmp_it.charpos; + new_pos.bytepos = -1; + } + else + new_pos = it.current.pos; + while (it.current_x + it.pixel_width <= target_x && rc == MOVE_X_REACHED) { int new_x = it.current_x + it.pixel_width; - new_pos = it.current.pos; + /* For composed characters, we want the position of the + first character in the grapheme cluster (usually, the + composition's base character), whereas it.current + might give us the position of the _last_ one, e.g. if + the composition is rendered in reverse due to bidi + reordering. */ + if (it.what == IT_COMPOSITION) + { + new_pos.charpos = it.cmp_it.charpos; + new_pos.bytepos = -1; + } + else + new_pos = it.current.pos; if (new_x == it.current_x) new_x++; rc = move_it_in_display_line_to (&it, ZV, new_x, @@ -20715,21 +20751,10 @@ if (ITERATOR_AT_END_OF_LINE_P (&it) && !target_is_eol_p) break; } - /* If we ended up on a composed character inside - bidi-reordered text (e.g., Hebrew text with diacritics), - the iterator gives us the buffer position of the last (in - logical order) character of the composed grapheme cluster, - which is not what we want. So we cheat: we compute the - character position of the character that follows (in the - logical order) the one where the above loop stopped. That - character will appear on display to the left of point. */ - if (it.bidi_p - && it.bidi_it.scan_dir == -1 - && new_pos.charpos - IT_CHARPOS (it) > 1) - { - new_pos.charpos = IT_CHARPOS (it) + 1; - new_pos.bytepos = CHAR_TO_BYTE (new_pos.charpos); - } + /* The previous position we saw in the loop is the one we + want. */ + if (new_pos.bytepos == -1) + new_pos.bytepos = CHAR_TO_BYTE (new_pos.charpos); it.current.pos = new_pos; } else ------------------------------------------------------------ revno: 115550 committer: Paul Eggert branch nick: trunk timestamp: Mon 2013-12-16 10:05:53 -0800 message: * font.h (valid_font_driver) [!ENABLE_CHECKING]: Define a dummy. This prevents a compilation error on C compilers that do not default functions to return 'int' if not declared. Also, add INLINE_HEADER_BEGIN and INLINE_HEADER_END to this include file, since it now uses inline functions. diff: === modified file 'src/ChangeLog' --- src/ChangeLog 2013-12-16 17:59:50 +0000 +++ src/ChangeLog 2013-12-16 18:05:53 +0000 @@ -1,3 +1,11 @@ +2013-12-16 Paul Eggert + + * font.h (valid_font_driver) [!ENABLE_CHECKING]: Define a dummy. + This prevents a compilation error on C compilers that do not + default functions to return 'int' if not declared. Also, add + INLINE_HEADER_BEGIN and INLINE_HEADER_END to this include file, + since it now uses inline functions. + 2013-12-16 Eli Zaretskii * xdisp.c (extend_face_to_end_of_line): Don't fill background of === modified file 'src/font.h' --- src/font.h 2013-12-16 07:45:33 +0000 +++ src/font.h 2013-12-16 18:05:53 +0000 @@ -25,6 +25,8 @@ #include "ccl.h" #include "frame.h" +INLINE_HEADER_BEGIN + /* We have three types of Lisp objects related to font. FONT-SPEC @@ -789,6 +791,12 @@ extern void free_font_driver_list (struct frame *f); #ifdef ENABLE_CHECKING extern bool valid_font_driver (struct font_driver *); +#else +INLINE bool +valid_font_driver (struct font_driver *d) +{ + return true; +} #endif extern Lisp_Object font_update_drivers (struct frame *f, Lisp_Object list); extern Lisp_Object font_range (ptrdiff_t, ptrdiff_t, ptrdiff_t *, @@ -862,4 +870,6 @@ font_deferred_log ((ACTION), (ARG), (RESULT)); \ } while (false) +INLINE_HEADER_END + #endif /* not EMACS_FONT_H */ ------------------------------------------------------------ revno: 115549 fixes bug: http://debbugs.gnu.org/16165 committer: Eli Zaretskii branch nick: trunk timestamp: Mon 2013-12-16 19:59:50 +0200 message: Fix bug #16165 with memory corruption by extend_face_to_end_of_line. src/xdisp.c (extend_face_to_end_of_line): Don't fill background of display margins on mode line, header line, and in the frame's tool-bar window. diff: === modified file 'src/ChangeLog' --- src/ChangeLog 2013-12-16 16:14:45 +0000 +++ src/ChangeLog 2013-12-16 17:59:50 +0000 @@ -1,3 +1,9 @@ +2013-12-16 Eli Zaretskii + + * xdisp.c (extend_face_to_end_of_line): Don't fill background of + display margins on mode line, header line, and in the frame's + tool-bar window. (Bug#16165) + 2013-12-16 Andreas Schwab * gnutls.c (Fgnutls_boot): Properly check Flistp return value. === modified file 'src/xdisp.c' --- src/xdisp.c 2013-12-15 16:51:59 +0000 +++ src/xdisp.c 2013-12-16 17:59:50 +0000 @@ -18863,19 +18863,26 @@ it->glyph_row->glyphs[TEXT_AREA][0].face_id = face->id; it->glyph_row->used[TEXT_AREA] = 1; } - if (WINDOW_LEFT_MARGIN_WIDTH (it->w) > 0 - && it->glyph_row->used[LEFT_MARGIN_AREA] == 0) - { - it->glyph_row->glyphs[LEFT_MARGIN_AREA][0] = space_glyph; - it->glyph_row->glyphs[LEFT_MARGIN_AREA][0].face_id = face->id; - it->glyph_row->used[LEFT_MARGIN_AREA] = 1; - } - if (WINDOW_RIGHT_MARGIN_WIDTH (it->w) > 0 - && it->glyph_row->used[RIGHT_MARGIN_AREA] == 0) - { - it->glyph_row->glyphs[RIGHT_MARGIN_AREA][0] = space_glyph; - it->glyph_row->glyphs[RIGHT_MARGIN_AREA][0].face_id = face->id; - it->glyph_row->used[RIGHT_MARGIN_AREA] = 1; + /* Mode line and the header line don't have margins, and + likewise the frame's tool-bar window, if there is any. */ + if (!(it->glyph_row->mode_line_p + || (WINDOWP (f->tool_bar_window) + && it->w == XWINDOW (f->tool_bar_window)))) + { + if (WINDOW_LEFT_MARGIN_WIDTH (it->w) > 0 + && it->glyph_row->used[LEFT_MARGIN_AREA] == 0) + { + it->glyph_row->glyphs[LEFT_MARGIN_AREA][0] = space_glyph; + it->glyph_row->glyphs[LEFT_MARGIN_AREA][0].face_id = face->id; + it->glyph_row->used[LEFT_MARGIN_AREA] = 1; + } + if (WINDOW_RIGHT_MARGIN_WIDTH (it->w) > 0 + && it->glyph_row->used[RIGHT_MARGIN_AREA] == 0) + { + it->glyph_row->glyphs[RIGHT_MARGIN_AREA][0] = space_glyph; + it->glyph_row->glyphs[RIGHT_MARGIN_AREA][0].face_id = face->id; + it->glyph_row->used[RIGHT_MARGIN_AREA] = 1; + } } #ifdef HAVE_WINDOW_SYSTEM if (it->glyph_row->reversed_p) ------------------------------------------------------------ revno: 115548 committer: Paul Eggert branch nick: trunk timestamp: Mon 2013-12-16 09:58:25 -0800 message: * INSTALL: Clarify treatment of image libraries. diff: === modified file 'ChangeLog' --- ChangeLog 2013-12-14 22:06:30 +0000 +++ ChangeLog 2013-12-16 17:58:25 +0000 @@ -1,3 +1,7 @@ +2013-12-16 Paul Eggert + + * INSTALL: Clarify treatment of image libraries. + 2013-12-14 Paul Eggert Use bool for boolean, focusing on headers. === modified file 'INSTALL' --- INSTALL 2013-12-13 18:25:30 +0000 +++ INSTALL 2013-12-16 17:58:25 +0000 @@ -62,9 +62,8 @@ name, where to find various headers and libraries, etc. Refer to the section DETAILED BUILDING AND INSTALLATION below. - If `configure' didn't find some (optional) image support libraries, - such as Xpm, jpeg, etc., and you want to use them, refer to the - subsection "Image support libraries" below. + If `configure' didn't find some image support libraries, such as + Xpm and jpeg, refer to "Image support libraries" below. If the details printed by `configure' don't make any sense to you, but there are no obvious errors, assume that `configure' did @@ -142,37 +141,40 @@ * Image support libraries -Emacs needs optional libraries to be able to display images (with the -exception of PBM and XBM images whose support is built-in). +Emacs needs libraries to display images, with the exception of PBM and +XBM images whose support is built-in. On some systems, particularly on GNU/Linux, these libraries may -already be present or available as additional packages. Note that if +already be present or available as additional packages. If there is a separate `dev' or `devel' package, for use at compilation time rather than run time, you will need that as well as the corresponding run time package; typically the dev package will contain header files and a library archive. Otherwise, you can -download and build libraries from sources. None of them are vital for -running Emacs; however, note that Emacs will not be able to use -colored icons in the toolbar if XPM support is not compiled in. - -Here's the list of some of these optional libraries, and the URLs -where they can be found (in the unlikely event that your distribution -does not provide them): - - . libXaw3d http://directory.fsf.org/project/xaw3d/ - . libxpm for XPM: http://www.x.org/releases/current/src/lib/ - . libpng for PNG: http://www.libpng.org/ - . libz (for PNG): http://www.zlib.net/ - . libjpeg for JPEG: http://www.ijg.org/ - . libtiff for TIFF: http://www.remotesensing.org/libtiff/ - . libgif for GIF: http://sourceforge.net/projects/giflib/ - -Emacs will configure itself to build with these libraries if the -`configure' script finds them on your system, unless you supply the -appropriate --without-LIB option. In some cases, older versions of -these libraries won't work because some routines are missing, and -configure should avoid such old versions. If that happens, use the ---without-LIB options to `configure', if you need to. +download and build libraries from sources. Although none of them are +essential for running Emacs, some are important enough that +'configure' will report an error if they are absent from a system that +has X11 support, unless 'configure' is specifically told to omit them. + +Here's a list of some of these libraries, and the URLs where they +can be found (in the unlikely event that your distribution does not +provide them). By default, libraries marked with an X are required if +X11 is being used. + + libXaw3d http://directory.fsf.org/project/xaw3d/ + X libxpm for XPM: http://www.x.org/releases/current/src/lib/ + X libpng for PNG: http://www.libpng.org/ + libz (for PNG): http://www.zlib.net/ + X libjpeg for JPEG: http://www.ijg.org/ + X libtiff for TIFF: http://www.remotesensing.org/libtiff/ + X libgif for GIF: http://sourceforge.net/projects/giflib/ + +If you supply the appropriate --without-LIB option, 'configure' will +omit the corresponding library from Emacs, even if that makes for a +less-pleasant user interface. Otherwise, Emacs will configure itself +to build with these libraries if 'configure' finds them on your +system, and 'configure' will complain and exit if a library marked 'X' +is not found on a system that uses X11. Use --without-LIB if your +version of a library won't work because some routines are missing. * Extra fonts @@ -280,7 +282,7 @@ For image support you may have to download, build, and install the appropriate image support libraries for image types other than XBM and -PBM, see the list of URLs in "ADDITIONAL DISTRIBUTION FILES" above. +PBM, see the list of URLs in "Image support libraries" above. (Note that PNG support requires libz in addition to libpng.) To disable individual types of image support in Emacs for some reason, ------------------------------------------------------------ revno: 115547 committer: Andreas Schwab branch nick: emacs timestamp: Mon 2013-12-16 17:18:19 +0100 message: Add more .gitignore diff: === added file 'lisp/cedet/.gitignore' --- lisp/cedet/.gitignore 1970-01-01 00:00:00 +0000 +++ lisp/cedet/.gitignore 2013-12-16 16:18:19 +0000 @@ -0,0 +1,8 @@ +## Generated grammar files. +semantic/bovine/c-by.el +semantic/bovine/make-by.el +semantic/bovine/scm-by.el +semantic/wisent/javat-wy.el +semantic/wisent/js-wy.el +semantic/wisent/python-wy.el +srecode/srt-wy.el ------------------------------------------------------------ revno: 115546 committer: Andreas Schwab branch nick: emacs timestamp: Mon 2013-12-16 17:14:45 +0100 message: * gnutls.c (Fgnutls_boot): Properly check Flistp return value. diff: === modified file 'src/ChangeLog' --- src/ChangeLog 2013-12-16 15:47:09 +0000 +++ src/ChangeLog 2013-12-16 16:14:45 +0000 @@ -1,3 +1,7 @@ +2013-12-16 Andreas Schwab + + * gnutls.c (Fgnutls_boot): Properly check Flistp return value. + 2013-12-16 Teodor Zlatanov * gnutls.c (Fgnutls_boot): Use `Flistp' instead of === modified file 'src/gnutls.c' --- src/gnutls.c 2013-12-16 15:47:09 +0000 +++ src/gnutls.c 2013-12-16 16:14:45 +0000 @@ -825,7 +825,7 @@ verify_error = Fplist_get (proplist, QCgnutls_bootprop_verify_error); prime_bits = Fplist_get (proplist, QCgnutls_bootprop_min_prime_bits); - if (!Flistp (verify_error)) + if (NILP (Flistp (verify_error))) error ("gnutls-boot: invalid :verify_error parameter (not a list)"); if (!STRINGP (hostname)) ------------------------------------------------------------ revno: 115545 committer: Ted Zlatanov branch nick: quickfixes timestamp: Mon 2013-12-16 10:49:25 -0500 message: Cleanup cfengine3-mode so complete-symbol works again. * progmodes/cfengine.el (cfengine3--current-word): Remove. (cfengine3--current-function): Bring in the current-function functionality from `cfengine3--current-word'. (cfengine3-completion-function): Bring in the bounds-of-current-word functionality from `cfengine3--current-word'. diff: === modified file 'lisp/ChangeLog' --- lisp/ChangeLog 2013-12-16 09:58:44 +0000 +++ lisp/ChangeLog 2013-12-16 15:49:25 +0000 @@ -1,3 +1,12 @@ +2013-12-16 Teodor Zlatanov + + * progmodes/cfengine.el (cfengine3--current-word): Remove. + (cfengine3--current-function): Bring in the current-function + functionality from `cfengine3--current-word'. + (cfengine3-completion-function): Bring in the + bounds-of-current-word functionality from + `cfengine3--current-word'. + 2013-12-16 Martin Rudalics * window.el (display-buffer-below-selected): Bind === modified file 'lisp/progmodes/cfengine.el' --- lisp/progmodes/cfengine.el 2013-12-13 19:49:56 +0000 +++ lisp/progmodes/cfengine.el 2013-12-16 15:49:25 +0000 @@ -1165,24 +1165,18 @@ ;; CLASS: [.|&!()a-zA-Z0-9_\200-\377]+:: ;; CATEGORY: [a-zA-Z_]+: -(defun cfengine3--current-word (&optional bounds) - "Propose a word around point in the current CFEngine 3 buffer." - (save-excursion - (skip-syntax-forward "w_") - (when (search-backward-regexp - cfengine-mode-syntax-functions-regex - (point-at-bol) - t) - (if bounds - (list (point) (match-end 1)) - (match-string 1))))) - (defun cfengine3--current-function () "Look up current CFEngine 3 function" (let* ((syntax (cfengine3-make-syntax-cache)) (flist (assq 'functions syntax))) (when flist - (let ((w (cfengine3--current-word))) + (let ((w (save-excursion + (skip-syntax-forward "w_") + (when (search-backward-regexp + cfengine-mode-syntax-functions-regex + (point-at-bol) + t) + (match-string 1))))) (and w (assq (intern w) flist)))))) ;; format from "cf-promises -s json", e.g. "sort" function: @@ -1271,7 +1265,10 @@ (defun cfengine3-completion-function () "Return completions for function name around or before point." (cfengine3-make-syntax-cache) - (let* ((bounds (cfengine3--current-word t)) + (let* ((bounds (save-excursion + (let ((p (point))) + (skip-syntax-backward "w_" (point-at-bol)) + (list (point) p)))) (syntax (cfengine3-make-syntax-cache)) (flist (assq 'functions syntax))) (when bounds ------------------------------------------------------------ revno: 115544 committer: Ted Zlatanov branch nick: quickfixes timestamp: Mon 2013-12-16 10:47:09 -0500 message: Fix bug#16161: CHECK_LIST_CONS fails on nil * src/gnutls.c (Fgnutls_boot): Use `Flistp' instead of `CHECK_LIST_CONS`. diff: === modified file 'src/ChangeLog' --- src/ChangeLog 2013-12-16 09:58:44 +0000 +++ src/ChangeLog 2013-12-16 15:47:09 +0000 @@ -1,3 +1,8 @@ +2013-12-16 Teodor Zlatanov + + * gnutls.c (Fgnutls_boot): Use `Flistp' instead of + `CHECK_LIST_CONS`. + 2013-12-16 Martin Rudalics * w32term.c (w32_enable_frame_resize_hack): Default to 1. === modified file 'src/gnutls.c' --- src/gnutls.c 2013-12-15 04:20:53 +0000 +++ src/gnutls.c 2013-12-16 15:47:09 +0000 @@ -825,7 +825,8 @@ verify_error = Fplist_get (proplist, QCgnutls_bootprop_verify_error); prime_bits = Fplist_get (proplist, QCgnutls_bootprop_min_prime_bits); - CHECK_LIST_CONS (verify_error, verify_error); + if (!Flistp (verify_error)) + error ("gnutls-boot: invalid :verify_error parameter (not a list)"); if (!STRINGP (hostname)) error ("gnutls-boot: invalid :hostname parameter (not a string)"); ------------------------------------------------------------ revno: 115543 committer: martin rudalics branch nick: trunk timestamp: Mon 2013-12-16 10:58:44 +0100 message: Fix recent w32_enable_frame_resize_hack and display-buffer-below-selected fixes. * w32term.c (w32_enable_frame_resize_hack): Default to 1. * window.el (display-buffer-below-selected): Bind split-height-threshold to 0 as suggested by Juri Linkov. diff: === modified file 'lisp/ChangeLog' --- lisp/ChangeLog 2013-12-16 08:07:10 +0000 +++ lisp/ChangeLog 2013-12-16 09:58:44 +0000 @@ -1,3 +1,8 @@ +2013-12-16 Martin Rudalics + + * window.el (display-buffer-below-selected): Bind + split-height-threshold to 0 as suggested by Juri Linkov. + 2013-12-16 Leo Liu * progmodes/compile.el (compile-goto-error): Do not push-mark. === modified file 'lisp/window.el' --- lisp/window.el 2013-12-14 17:00:54 +0000 +++ lisp/window.el 2013-12-16 09:58:44 +0000 @@ -6245,7 +6245,8 @@ the selected one." (let (window) (or (and (not (frame-parameter nil 'unsplittable)) - (let (split-width-threshold) + (let ((split-height-threshold 0) + split-width-threshold) (setq window (window--try-to-split-window (selected-window) alist))) (window--display-buffer buffer window 'window alist display-buffer-mark-dedicated)) === modified file 'src/ChangeLog' --- src/ChangeLog 2013-12-16 07:45:33 +0000 +++ src/ChangeLog 2013-12-16 09:58:44 +0000 @@ -1,3 +1,7 @@ +2013-12-16 Martin Rudalics + + * w32term.c (w32_enable_frame_resize_hack): Default to 1. + 2013-12-16 Dmitry Antipov * font.c (valid_font_driver) [ENABLE_CHECKING]: New function === modified file 'src/w32term.c' --- src/w32term.c 2013-12-15 17:40:44 +0000 +++ src/w32term.c 2013-12-16 09:58:44 +0000 @@ -6679,7 +6679,7 @@ windows after the latter calls back. If this is non-nil, Emacs changes the pixel sizes of the frame and its windows at the time it sends the resize request to the API. */); - w32_enable_frame_resize_hack = 0; + w32_enable_frame_resize_hack = 1; /* Tell Emacs about this window system. */ Fprovide (Qw32, Qnil); ------------------------------------------------------------ revno: 115542 committer: Leo Liu branch nick: trunk timestamp: Mon 2013-12-16 16:07:10 +0800 message: * progmodes/compile.el (compile-goto-error): Do not push-mark. Remove NOMSG arg and all uses changed. diff: === modified file 'lisp/ChangeLog' --- lisp/ChangeLog 2013-12-16 02:24:08 +0000 +++ lisp/ChangeLog 2013-12-16 08:07:10 +0000 @@ -1,3 +1,8 @@ +2013-12-16 Leo Liu + + * progmodes/compile.el (compile-goto-error): Do not push-mark. + Remove NOMSG arg and all uses changed. + 2013-12-16 Stefan Monnier * emulation/cua-rect.el (cua-rectangle-mark-mode): New minor mode. === modified file 'lisp/progmodes/compile.el' --- lisp/progmodes/compile.el 2013-12-06 15:34:06 +0000 +++ lisp/progmodes/compile.el 2013-12-16 08:07:10 +0000 @@ -1004,7 +1004,7 @@ (let ((win (get-buffer-window buffer 0))) (if win (set-window-point win pos))) (if compilation-auto-jump-to-first-error - (compile-goto-error nil t)))) + (compile-goto-error)))) ;; This function is the central driver, called when font-locking to gather ;; all information needed to later jump to corresponding source code. @@ -2325,9 +2325,9 @@ (defalias 'compile-mouse-goto-error 'compile-goto-error) -(defun compile-goto-error (&optional event nomsg) +(defun compile-goto-error (&optional event) "Visit the source for the error message at point. -Use this command in a compilation log buffer. Sets the mark at point there." +Use this command in a compilation log buffer." (interactive (list last-input-event)) (if event (posn-set-point (event-end event))) (or (compilation-buffer-p (current-buffer)) @@ -2336,7 +2336,6 @@ (if (get-text-property (point) 'compilation-directory) (dired-other-window (car (get-text-property (point) 'compilation-directory))) - (push-mark nil nomsg) (setq compilation-current-error (point)) (next-error-internal)))