summaryrefslogtreecommitdiff
path: root/lisp
Commit message (Collapse)AuthorAgeFilesLines
* Add 'rx' pattern for pcase.Philipp Stephani2017-07-232-1/+56
| | | | | * lisp/emacs-lisp/rx.el (rx): New pcase macro. * test/lisp/emacs-lisp/rx-tests.el (rx-pcase): Add unit test.
* Use a named function for global minor mode turn-on argumentMark Oteiza2017-07-231-6/+9
| | | | | | * lisp/display-line-numbers.el (turn-on-display-line-numbers-mode): New function. (global-display-line-numbers-mode): Use it.
* Convert CC Mode's c-found-types from an obarray to a hash table.Alan Mackenzie2017-07-231-18/+10
| | | | | | | | | * lisp/progmodes/cc-engine.el (c-clear-found-types): create a hash table rather than an obarray. (c-copy-found-types): Remove. (c-add-type, c-unfind-type, c-check-type, c-list-found-types): Amend to use the new hash table. (c-forward-<>-arglist): Use copy-hash-table rather than c-copy-found-types.
* Fix image/svg+xml display in shrLars Ingebrigtsen2017-07-231-1/+1
| | | | | | * lisp/net/shr.el (shr-put-image): Display svg images as svg (bug#27799). I suspect the previous change was checked in by accident in conjuction with some other svg changes.
* * lisp/display-line-numbers.el (display-line-numbers-type): Autoload it.Michael Albinus2017-07-231-0/+1
|
* Add line numbers display to the Options menuMichael Albinus2017-07-221-11/+56
| | | | | | | * lisp/menu-bar.el (toggle-display-line-numbers): Remove. (menu-bar-display-line-numbers-mode): New defun. (menu-bar-showhide-line-numbers-menu): New defvar. (menu-bar-showhide-menu): Use `menu-bar-showhide-line-numbers-menu'
* Revert "Let delete-selection-mode work with popup-menu commands (Bug#27569)"Noam Postavsky2017-07-221-4/+0
| | | | | | | | It turns out that this change is not needed, and it leaves several command loops settings not done. https://lists.gnu.org/archive/html/emacs-devel/2017-07/msg00757.html https://lists.gnu.org/archive/html/emacs-devel/2017-07/msg00840.html
* Add a minor mode interface for display-line-numbersAlexander Gramiak2017-07-222-4/+107
| | | | | | | | | | | | | | | * lisp/cus-start.el: Use the new display-line-numbers group. * lisp/display-line-numbers.el: New file. * doc/emacs/custom.texi (Init Rebinding): Re-add entry that used to belong to linum-mode. * doc/emacs/modes.texi (Minor Modes): Summarize the mode. * etc/NEWS: Document display-line-numbers-mode and its customization variables, and mention that display-line-numbers-width is buffer-local. * src/xdisp.c (syms_of_xdisp) <display-line-numbers-width>: Fix a typo.
* Support indented HERE-DOCs in cperl-modevividsnow2017-07-221-2/+2
| | | | | | | * lisp/progmodes/cperl-mode.el (cperl-find-pods-heres): Support indented here-docs. (Bug#27254) (Bug#27697) Copyright-paperwork-exempt: yes
* Add 'scroll-bar-mode' to settings in 'x-apply-session-resources'Matthew Bauer2017-07-221-0/+1
| | | | | | | * lisp/startup.el (x-apply-session-resources): Add scroll-bar-mode settings. Copyright-paperwork-exempt: yes
* Update ld-script mode (bug#27629)Alexander Kuleshov2017-07-221-3/+6
| | | | | | | * lisp/progmodes/ld-script.el: (ld-script-keywords): New commands NOCROSSREFS_TO and HIDDEN added. Fix documentation sections numbers for PROVIDE/PROVIDE_HIDDEN commands. (ld-script-builtins): New builtin function LOG2CEIL added.
* * lisp/subr.el (add-to-history): Doc fix. (Bug#27494)Eli Zaretskii2017-07-221-1/+2
|
* Doc fixes for kmacro.el functionsEli Zaretskii2017-07-221-5/+6
| | | | | | * lisp/kmacro.el (kmacro-start-macro, kmacro-call-macro) (kmacro-end-and-call-macro): Don't use "permanent name", as that could be misinterpreted. (Bug#27492)
* ElDoc: add docstrings and minor refactoringCharles A. Roelli2017-07-221-11/+38
| | | | | | | | | | | | | | | | | | | | * lisp/emacs-lisp/eldoc.el (eldoc-edit-message-commands): Add docstring. (turn-on-eldoc-mode): Fix capitalization. (eldoc--supported-p): Add docstring. (eldoc-schedule-timer): Add docstring and use 'eldoc--supported-p'. (eldoc-message): Add docstring and make calling convention clearer. (eldoc--message-command-p): (eldoc-pre-command-refresh-echo-area): (eldoc-display-message-p): (eldoc-display-message-no-interference-p): (eldoc-print-current-symbol-info): (eldoc-docstring-format-sym-doc): (eldoc-add-command, eldoc-add-command-completions): (eldoc-remove-command, eldoc-remove-command-completions): Add docstring. (Bug#27230)
* Introduce defcustom 'executable-prefix-env'Andrew L. Moore2017-07-221-11/+25
| | | | | | | | | * lisp/progmodes/executable.el (executable-prefix): Update the doc string. (executable-prefix-env): New defcustom. (executable-set-magic): Use executable-prefix-env. * etc/NEWS: Document the new variable.
* Use lexical-binding in todo-mode.elStefan Monnier2017-07-211-132/+157
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Adjust code accordingly and make various minor improvements. * lisp/calendar/todo-mode.el: Enable lexical-binding. (dayname, monthname, day, month, year): Make forward defvars of these keywords from macros defined in calendar.el; wrap them in with-no-warnings. (todo-files, todo-files-function, todo-date-pattern) (todo-mode-line-function, todo-show, todo-forward-category) (todo-edit-item--header, todo-set-category-number) (todo-adjusted-category-label-length) (todo-total-item-counts, todo-filter-items) (todo-print-buffer-function, todo-convert-legacy-date-time) (todo-category-number, todo-category-completions) (todo-read-file-name, todo-read-category) (todo-validate-name, todo-read-date) (todo-set-show-current-file, todo-modes-set-1) (todo-modes-set-2, todo-modes-set-3, todo-mode): Use #' instead of ' to quote functions. (todo-files): Use \' instead of $ in regexp. (todo--files-type-list): New function. (todo-default-todo-file, todo-category-completions-files) (todo-filter-files, todo-multiple-filter-files) (todo-reevaluate-default-file-defcustom) (todo-reevaluate-category-completions-files-defcustom) (todo-reevaluate-filter-files-defcustom): Use it. (todo-show, todo-rename-file, todo-move-category) (todo-edit-item--text, todo-edit-quit, todo-edit-item--header) (todo-item-undone, todo-unarchive-items, todo-search) (todo-filter-items, todo-filter-items-1, todo-find-item) (todo-category-select, todo-read-date) (todo-nondiary-marker-matcher, todo-date-string-matcher) (todo-diary-expired-matcher, todo-convert-legacy-files) (todo-read-category): Reformat to avoid code hiding behind a more deeply embedded element. (todo-forward-category, todo-set-category-number): Use 'funcall' instead of 'apply'. (todo-toggle-mark-item, todo-edit-item--diary-inclusion) (todo-edit-category-diary-inclusion) (todo-insert-sort-button, todo-insert-category-line) (todo-multiple-filter-files): Mark unused local variables. (todo-edit-item--header, todo-move-item, todo-print-buffer) (todo-edit-item--header, todo-move-item, todo-check-file) (todo-edit-item--next-key): Remove unused local variables. (todo-insert-sort-button, todo-insert-category-line): Use a closure instead of a backquoted lambda. (todo-update-categories-display, todo-print-buffer): Simplify code. (todo-print-buffer-function): Document calling convention. (todo-category-completions): Use cl-pushnew instead of add-to-list. (todo-mode-map, todo-archive-mode-map) (todo-categories-mode-map, todo-filtered-items-mode-map): Remove superfluous call of suppress-keymap, since it's already in the parent special-mode-map.
* dired: Revert buffer when DIRNAME is a consTino Calancha2017-07-211-2/+9
| | | | | | | * lisp/dired.el (dired-internal-noselect): Revert buffer if DIR-OR-LIST is a cons, or dired-directory is a cons and DIR-OR-LIST a string (Bug#7131). Update the comments. * test/lisp/dired-tests.el (dired-test-bug7131): Test should pass.
* Handle when dired-directory is a cons in some Dired functionsTino Calancha2017-07-212-4/+12
| | | | | | * lisp/dired-aux.el (dired-rename-subdir-1) * lisp/dired-x.el (dired-mark-omitted): Handle when dired-directory is a cons.
* Make eshell-next-prompt more reliable (Bug#27405)Noam Postavsky2017-07-201-2/+13
| | | | | | | | * lisp/eshell/em-prompt.el (eshell-next-prompt): Search for `eshell-prompt-regexp' (and `read-only' text-property if `eshell-highlight-prompt' is set) rather than trying to use `forward-paragraph'. (eshell-previous-prompt): Don't count prompt on current line.
* ; Spelling fixesPaul Eggert2017-07-201-2/+2
|
* Stylistic changes in tramp-cache.elMichael Albinus2017-07-201-4/+4
| | | | | | * test/lisp/net/tramp-cache.el (tramp-get-file-property) (tramp-set-file-property): Use `bound-and-true-p'. Add counter variables to `tramp-cache-unload-hook'.
* Make tramp unloading handle debug counter variablesGlenn Morris2017-07-201-2/+10
| | | | | * lisp/net/tramp-cache.el (tramp-get-file-property) (tramp-set-file-property): Add counter variables to tramp-unload-hook.
* Fix the bogus change made 13 years ago (bug#27084)Katsumi Yamaoka2017-07-201-2/+5
| | | | | * lisp/gnus/gnus-sum.el (gnus-summary-toggle-header): Fix the way to test if there is no visible header (bug#27084).
* Use grep's --null option (Bug#6843)Noam Postavsky2017-07-192-44/+93
| | | | | | | | | | | | | | | | | | | * lisp/progmodes/grep.el (grep-use-null-filename-separator): New option. (grep--regexp-alist-column, grep--regexp-alist-bin-matcher) (grep-with-null-regexp-alist, grep-fallback-regexp-alist): New constants, replacing `grep-regexp-alist'. (grep-regex-alist): Mark the variable obsolete, add a new function of the same name to replace it. (grep-compute-defaults): Compute default for `grep-use-null-filename-separator'. (grep-mode): Set compilation-error-regexp-alist (buffer locally) to the value of `grep-with-null-regexp-alist' or `grep-fallback-regexp-alist' according to `grep-use-null-filename-separator'. * lisp/progmodes/xref.el (xref-collect-matches): Call `grep-regex-alist' instead of the obsolete variable. Don't hardcode grep-regexp-alist match groups. * etc/NEWS: Announce new use of --null. Move 'grep-save-buffers' item under "Grep" heading as well.
* Adjust todo-quit to recent change in diredStephen Berman2017-07-191-1/+1
| | | | | | | | * lisp/calendar/todo-mode.el (todo-quit): Use quit-window instead of bury-buffer to exit todo-mode. This restores the desired behavior of not immediately returning to the exited todo-mode buffer on quitting another buffer, which a dired bug fix had changed (see http://lists.gnu.org/archive/html/emacs-devel/2017-07/msg00739.html).
* * lisp/emacs-lisp/nadvice.el (advice--defalias-fset): Strip advicesStefan Monnier2017-07-181-0/+12
| | | | This tries to make sure that (defalias F (symbol-function F)) stays a no-op.
* Use a more specific test for running on hydra.nixos.orgGlenn Morris2017-07-181-1/+1
| | | | | | | | | | | * lisp/emacs-lisp/ert.el (ert-summarize-tests-batch-and-exit): * test/Makefile.in (WRITE_LOG): * test/lisp/filenotify-tests.el: * test/lisp/emacs-lisp/eieio-tests/eieio-test-methodinvoke.el (eieio-test-method-order-list-6): * test/lisp/emacs-lisp/eieio-tests/eieio-tests.el (eieio-test-37-obsolete-name-in-constructor): * test/lisp/net/tramp-tests.el: Replace NIX_STORE with EMACS_HYDRA_CI.
* * emacs-lisp/cl-lib.el (cl--old-struct-type-of): Accept `[]'Stefan Monnier2017-07-181-1/+1
|
* Let delete-selection-mode work with popup-menu commands (Bug#27569)Noam Postavsky2017-07-181-0/+4
| | | | | * lisp/menu-bar.el (popup-menu): Run `pre-command-hook' with `this-command' set to the selected command.
* Fix relocation with named cell referred to by a one-symbol formula.Vincent Belaïche2017-07-171-4/+8
| | | | | | | | | * lisp/ses.el (ses-replace-name-in-formula): Fix bug for it to work also with one symbol formulas. * test/lisp/ses-tests.el (ses-tests-renaming-cell-with-one-symbol-formula): Add new test for renaming with relocating a one symbol formula.
* Fix symbol completion and document it.Vincent Belaïche2017-07-171-1/+171
| | | | | | | | | | | | | | | | | | | | | | | | | | * doc/misc/ses.texi (Configuring what printer function applies): Add description of keys for completing local printer symbols and listing local printers in a help buffer. (Formulas): Add decription for key to list the named cell symbols in a help buffer. * lisp/ses.el (ses-completion-keys): New constant. (ses--completion-table): New defvar. (ses--list-orig-buffer): New defvar. (ses-mode-edit-map): Fixed for symbol completion, plus add help functions to list named cells or local printers. (ses-edit-cell-complete-symbol) (ses--edit-cell-completion-at-point-function): New defuns for completion during formula edition. (ses-edit-cell): Redefine dynamically edit keymap for completion keys to point at the right function. (ses-read-printer-complete-symbol) (ses--read-printer-completion-at-point-function): New defuns for completion during printer edition. (ses-read-printer): Redefine dynamically edit keymap for completion keys to point at the right function. (ses-list-local-printers): New defun. (ses-list-named-cells): New defun.
* * lisp/emacs-lisp/map.el (map-put): Fix redundancy in docstring.Tino Calancha2017-07-171-2/+0
|
* alist-get: Add optional arg TESTFNTino Calancha2017-07-173-13/+23
| | | | | | | | | | | | If TESTFN is non-nil, then it is the predicate to lookup the alist. Otherwise, use 'eq' (Bug#27584). * lisp/subr.el (alist-get): Add optional arg FULL. * lisp/emacs-lisp/map.el (map-elt, map-put): Add optional arg TESTFN. * lisp/emacs-lisp/gv.el (alist-get): Update expander. * doc/lispref/lists.texi (Association Lists): Update manual. * etc/NEWS: Announce the changes. * test/lisp/emacs-lisp/map-tests.el (test-map-put-testfn-alist) (test-map-elt-testfn): New tests.
* Preserve point under 'dired-auto-revert-buffer' (second case)Stephen Berman2017-07-171-1/+1
| | | | | | | | * lisp/dired.el (dired): Use pop-to-buffer-same-window instead of switch-to-buffer. This preserves Dired window point when dired-auto-revert-buffer is non-nil. (Bug#27243) * test/lisp/dired-tests.el (dired-test-bug27243): New test.
* Fix vc-src-dir-status-filesDieter Deyke2017-07-171-1/+1
| | | | | * lisp/vc/vc-src.el (vc-src-dir-status-files): Fix broken copy-paste from b1a765b3 (bug#27641).
* Add missing declare-function for new functionAlan Third2017-07-161-0/+1
| | | | | * lisp/frame.el: Add declare function for ns-mouse-absolute-pixel-position.
* Fix some frame handling issues on NSAlan Third2017-07-151-0/+2
| | | | | | | * lisp/frame.el (mouse-absolute-pixel-position): Use new NS function. * src/nsfns.m (Sns_mouse_absolute_pixel_position): New function. * src/nsterm.m (x_make_frame_visible): Re-establish parent-child relationship if it's broken.
* ls-lisp: Fix file size formatTino Calancha2017-07-161-3/+3
| | | | | | * lisp/ls-lisp.el (ls-lisp-filesize-d-fmt, ls-lisp-filesize-f-fmt) (ls-lisp-filesize-b-fmt): Add space in front (Bug#27693). * test/lisp/dired-tests.el (dired-test-bug27693): Add test.
* Improve comments in faces.elEli Zaretskii2017-07-151-1/+6
| | | | | * lisp/faces.el (face-font-family-alternatives): Improve commentary.
* * lisp/emacs-lisp/bytecomp.el: Fix bug#14860.Stefan Monnier2017-07-144-38/+18
| | | | | | | | | | | | | | | | * lisp/emacs-lisp/bytecomp.el (byte-compile--function-signature): New fun. Dig into advice wrappers to find the "real" signature. (byte-compile-callargs-warn, byte-compile-arglist-warn): Use it. (byte-compile-arglist-signature): Don't bother with "new-style" arglists, since bytecode functions are now handled in byte-compile--function-signature. * lisp/files.el (create-file-buffer, insert-directory): Remove workaround introduced for (bug#14860). * lisp/help-fns.el (help-fns--analyse-function): `nadvice` is preloaded. * lisp/help.el (help-function-arglist): Dig into advice wrappers to find the "real" signature.
* * lisp/emacs-lisp/cl-lib.el (cl--random-time): Remove as wellStefan Monnier2017-07-141-5/+0
| | | | It's also defined in cl-extra.el.
* Do not convert ij and IJ to compatibility charsPaul Eggert2017-07-141-3/+0
| | | | | * lisp/leim/quail/latin-alt.el: Omit lines for ij and IJ in Dutch. Problem reported by James Cloos (Bug#518#10).
* Remove Turkish ligatures from Dutch input methodToon Claes2017-07-141-12/+1
| | | | * lisp/leim/quail/latin-alt.el: Remove Turkish ligatures (Bug#518).
* Remove duplicate cl--random-state definitionPaul Eggert2017-07-141-3/+0
| | | | | * lisp/emacs-lisp/cl-lib.el (cl--random-state): Remove. This variable is now defined in cl-extra.el (Bug#27617).
* Always display rmail progress report under user controlEli Zaretskii2017-07-141-2/+0
| | | | | * lisp/mail/rmail.el (rmail-show-message-1): Delete the second copy of '(message "Showing message %d..." msg)'. (Bug#27535)
* Avoid byte-compilation warnings for advised functionsEli Zaretskii2017-07-141-0/+9
| | | | | | * lisp/files.el (insert-directory, create-file-buffer): Add an advertised-calling-convention form to shut up byte-compilation warnings. (Bug#14860)
* Revert "Use fixed-pitch font for display-line-numbers"Eli Zaretskii2017-07-141-5/+2
| | | | | | | | | This reverts commit d014a5e15c1110af77e7a96f06ccd0f0cafb099f. * lisp/faces.el (line-number): Don't use a fixed-pitch font, by popular demand. For relevant discussions, see http://lists.gnu.org/archive/html/emacs-devel/2017-07/msg00433.html http://lists.gnu.org/archive/html/emacs-devel/2017-07/msg00445.html
* Merge branch 'master' of git.sv.gnu.org:/srv/git/emacsVincent Belaïche2017-07-136-45/+73
|\
| * C++ Mode. Fix anomaly occurring when a ">" is deleted then reinserted.Alan Mackenzie2017-07-132-21/+39
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This fontification anomaly happened because after deleting the ">", c-forward-<>-arglist parses the preceding identifier as a putative type but stores it in c-found-types before it becomes clear it is not an unambiguous type. c-forward-<>-arglist fails, leaving the spurious type id in c-found-types. Fix this by "binding" c-found-types "to itself" in c-forward-<>-arglist, and restoring the original value when that function call fails. * lisp/progmodes/cc-engine.el (c-copy-found-types): New function. (c-forward-<>-arglist): Record the original value of c-found-types at the beginning of the function, and restore it at the end on failure. * lisp/progmodes/cc-mode.el (c-unfind-coalesced-tokens): Rewrite more accurately.
| * Fix some bugs in c-defun-name. This fixes bug #25623.Alan Mackenzie2017-07-121-10/+17
| | | | | | | | | | * lisp/progmodes/cc-cmds.el (c-defun-name): Fix some bugs to do with structs, etc.