summaryrefslogtreecommitdiff
path: root/lisp/emacs-lisp
Commit message (Collapse)AuthorAgeFilesLines
* Allow newline after def*-form for definition-prefixStefan Kangas2022-08-051-1/+2
| | | | | | | * lisp/emacs-lisp/loaddefs-gen.el (autoload-ignored-definitions): Add another semantic function. (loaddefs-generate--compute-prefixes): Allow newline after the "(def*" form. (Bug#57000)
* Add variable end-of-defun-moves-to-eolFilipp Gunbin2022-08-051-1/+10
| | | | | * lisp/emacs-lisp/lisp.el (end-of-defun-moves-to-eol): New variable. (end-of-defun): Use it.
* timer.el: Avoid repeated timersStefan Monnier2022-08-051-29/+39
| | | | | | | | | https://mail.gnu.org/archive/html/emacs-devel/2022-07/msg01127.html points out that end-users can get bitten by this, accidentally calling `timer-activate` on an already activated timer. * lisp/emacs-lisp/timer.el (timer--activate): Signal an error if we try to re-add a timer that's already on the timer-list.
* bytecomp.el: Update comments referring to `make-docfile`Stefan Monnier2022-08-051-5/+5
|
* bytecomp.el: Further simplifications enabled by commit 59732a83c8875cStefan Monnier2022-08-051-3/+0
| | | | | | * lisp/emacs-lisp/bytecomp.el (byte-compile-output-docform): Don't insert a \n before the #@ docstrings since make-docfile doesn't scan .elc files any more.
* Be more lax when picking up prefixes for loaddefsStefan Kangas2022-08-041-1/+1
| | | | | | | | * lisp/emacs-lisp/loaddefs-gen.el (loaddefs-generate--compute-prefixes): Allow tabs and spaces before symbol name, so that "(defvar\tfoo-bar nil)" is properly picked up. Before this change, such a definition would be wrongly picked up as the symbol "nil".
* Move autoload.el to lisp/obsolete/Lars Ingebrigtsen2022-08-041-909/+0
|
* Minor cleanups in autoload.el/loaddefs-gen.elLars Ingebrigtsen2022-08-043-28/+6
| | | | | | | | | | | | | * lisp/subr.el (package--builtin-versions): Adjust comments. * lisp/emacs-lisp/loaddefs-gen.el (no-update-autoloads): Moved here from autoload.el. * lisp/emacs-lisp/loaddefs-gen.el: Removed now that it's no longer used. * lisp/emacs-lisp/package.el (package-autoload-ensure-default-file): Don't warn about soon-to-be obsolete functon.
* Minor checkdoc.el clean upLars Ingebrigtsen2022-08-041-2/+0
| | | | | * lisp/emacs-lisp/checkdoc.el (generate-autoload-cookie): This is no longer used, so remove reference.
* Add define-keymap to autoload-ignored-definitionsLars Ingebrigtsen2022-08-041-1/+1
| | | | | * lisp/emacs-lisp/loaddefs-gen.el (autoload-ignored-definitions): Ignore `define-keymap', too (bug#56973).
* Add define-key-after to autoload-ignored-definitionsStefan Kangas2022-08-041-2/+4
| | | | | * lisp/emacs-lisp/loaddefs-gen.el (autoload-ignored-definitions): Add define-key-after and define-ibuffer-sorter.
* Add more autoload-ignored-definitionsStefan Kangas2022-08-041-1/+2
| | | | | * lisp/emacs-lisp/loaddefs-gen.el (autoload-ignored-definitions): Add define-ibuffer-column.
* Add more autoload-ignored-definitions defsLars Ingebrigtsen2022-08-041-1/+4
| | | | | | * lisp/emacs-lisp/loaddefs-gen.el (autoload-ignored-definitions): Add more definition forms that shouldn't trigger prefix registration (bug#56970).
* Fix up some prefix registration problems in doc stringsLars Ingebrigtsen2022-08-041-3/+3
| | | | | | | | * lisp/uniquify.el (uniquify-buffer-name-style): * lisp/org/ob-core.el (org-src-sha): * lisp/emacs-lisp/cl-macs.el (cl--optimize): * lisp/battery.el (battery-update-functions): Avoid triggering the `register-definition-prefixes' in doc strings (bug#56968).
* Adjust loaddefs-generate--print-form commentsLars Ingebrigtsen2022-08-041-6/+7
| | | | | | * lisp/emacs-lisp/loaddefs-gen.el (loaddefs-generate--print-form): Adjust doc string and comments now that make-docfile doesn't scan this.
* Byte-compile the in-tree loaddefs.el filesLars Ingebrigtsen2022-08-031-1/+2
| | | | | | | | | | | | | | | | | * lisp/Makefile.in (all): Add "autoloads", which now otherwise won't be done. ($(lisp)/loaddefs.el): Remove this target, since it's always done, and would then trigger a re-compilation of loaddefs.elc. * lisp/loadup.el: Load loaddefs.elc (if it exists). * lisp/emacs-lisp/loaddefs-gen.el (loaddefs-generate): Don't include no-byte-compile cookies in the Emacs build. * src/Makefile.in ($(pdmp)): Depend on loaddefs.elc to ensure that it's built by this point. ($(etc)/DOC): Don't scan loaddefs.el for doc strings, since they are now picked up from the .elc file (bug#53024).
* Check for mis-quoted #' in doc strings during byte-compileLars Ingebrigtsen2022-08-031-1/+1
| | | | | * lisp/emacs-lisp/bytecomp.el (byte-compile-docstring-style-warn): Check for mis-quoted #' in doc strings, too.
* Fix quoting of #' in some doc stringsLars Ingebrigtsen2022-08-031-1/+1
| | | | | | | * lisp/org/ox.el (org-export-to-file): * lisp/eshell/esh-arg.el (eshell-concat): * lisp/emacs-lisp/edebug.el (edebug-read-special): * lisp/dired-aux.el (dired-split): Fix quoting of #' in doc strings.
* Remove some spurious references to XEmacsStefan Kangas2022-08-031-1/+1
| | | | | | * lisp/desktop.el (desktop--emacs-pid-running-p): * lisp/emacs-lisp/checkdoc.el (checkdoc-ispell-lisp-words): Don't mention XEmacs.
* Avoid cl-cXXXr compat aliasesStefan Kangas2022-08-032-14/+14
| | | | | | | | * lisp/emacs-lisp/cl-lib.el (cl-third, cl-fourth): * lisp/emacs-lisp/cl-macs.el (cl--do-&aux, cl--do-arglist) (cl--parse-loop-clause, cl--loop-let, cl--loop-build-ands) (cl--do-proclaim, cl-defstruct): Prefer using cXXXr functions directly, instead of cl-cXXXr prefixed compat aliases.
* Consider built-in packages to be installedMatt Armstrong2022-08-021-1/+4
| | | | | * lisp/emacs-lisp/package.el (package-installed-p): Check for built-in packages before initialization. (bug#56877).
* Don't disable eldoc when doing edebugLars Ingebrigtsen2022-08-021-1/+0
| | | | | | | | * lisp/emacs-lisp/eldoc.el (eldoc-display-message-no-interference-p): Don't disable eldoc when edebugging (bug#56459). There should be no interference in that case, because edebug messaging is done after stepping, and eldoc messaging is done after other movements.
* Fix the bytecode incompatibility due to the change to 'narrow-to-region'.Gregory Heytings2022-08-012-3/+6
| | | | | | | | | | | | | | | | | | | | | | | | | * src/editfns.c (narrow_to_region_internal): New function, which contains the body previously in 'Fnarrow_to_region' but accepts a third argument. (Fnarrow_to_region): Use the new function. Update the docstring. (Fwiden): Update the docstring. * src/lisp.h: Prototype of the new function. * src/xdisp.c (handle_fontified_prop): Use the new function instead of 'Fnarrow_to_region'. * src/process.c (Finternal_default_process_filter): * src/lread.c (readevalloop): Remove the third argument to 'Fnarrow_to_region'. * src/bytecode.c (exec_byte_code): * lisp/emacs-lisp/comp.el (comp-limplify-lap-inst): * lisp/emacs-lisp/bytecomp.el: Restore the statu quo ante. * etc/NEWS: Remove the entry about the new optional argument. * doc/lispref/positions.texi (Narrowing): Update the documentation.
* Omit some (current-time) callsPaul Eggert2022-08-012-2/+2
| | | | | | | | | | * lisp/emacs-lisp/ert.el (ert-write-junit-test-summary-report): * lisp/emacs-lisp/shortdoc.el (file): * lisp/find-lisp.el (find-lisp-find-dired-insert-file): * lisp/progmodes/hideif.el (hide-ifdefs): * lisp/tar-mode.el (tar-subfile-save-buffer): Prefer nil or omitted arg to (current-time) where this is better or more-efficient.
* Allow specifying that loaddefs files shouldn't not be compiledLars Ingebrigtsen2022-07-311-2/+5
| | | | | | * lisp/emacs-lisp/loaddefs-gen.el (loaddefs-generate--rubric): Allow specifying that we shouldn't include a no-compile cookie (bug#53024).
* Reduce internal rx autoloadsMattias Engdegård2022-07-311-4/+6
| | | | | | | * lisp/emacs-lisp/rx.el (rx--to-expr, rx--pcase-transform): Don't autoload. (rx--pcase-macroexpander): Extract body into... (rx--pcase-expand): ...a separate function, which is autoloaded.
* * lisp/emacs-lisp/eieio-base.el (eieio-persistent-read): Simplify.Stefan Kangas2022-07-311-26/+20
|
* Fix ede byte-compile warnings in loaddefs.elLars Ingebrigtsen2022-07-311-0/+1
| | | | | | * lisp/emacs-lisp/eieio.el (make-instance): * lisp/cedet/ede/auto.el (ede-add-project-autoload): Autoload functions referred to by ede/loaddefs.el.
* Remove loaddefs debug codeLars Ingebrigtsen2022-07-311-1/+0
| | | | | * lisp/emacs-lisp/loaddefs-gen.el (loaddefs-generate--rubric): Remove code inadvertantly checked in.
* Fix cl byte-compile warning in cl-loaddefs.elLars Ingebrigtsen2022-07-312-0/+4
| | | | | | * lisp/emacs-lisp/cl-macs.el (cl--optimize) (cl-struct-sequence-type, cl-struct-slot-offset): Autoload since they are referred to by code in cl-loaddefs.el.
* Fix remaining byte-compile warnings in loaddefs.elLars Ingebrigtsen2022-07-311-0/+1
| | | | | | | * lisp/progmodes/compile.el (compilation--default-buffer-name): * lisp/kmacro.el (kmacro-name-last-macro): * lisp/emacs-lisp/package.el (package--activate-all): Autoload to avoid byte-compilation warnings when byte-compiling loaddefs.el.
* Fix rx.el byte-compile warning in loaddefs.elLars Ingebrigtsen2022-07-311-0/+4
| | | | | * lisp/emacs-lisp/rx.el (rx--to-expr, rx--pcase-transform): Autoload to avoid warning when byte-compiling loaddefs.el.
* Fix further package.el loaddefs byte-compile warningsLars Ingebrigtsen2022-07-311-0/+3
| | | | | | | | * lisp/emacs-lisp/package.el (package-directory-list) (package-quickstart-file): Specify group to avoid warning when byte-compiling loaddefs.el. (package-activated-list): Autoload since we're assigning the variable from a function completely autoloaded.
* Fix loaddefs byte-compile warning from package.elLars Ingebrigtsen2022-07-311-0/+1
| | | | | * lisp/emacs-lisp/package.el (package-user-dir): :group has to be explicit for autoloaded defcustoms.
* Delete redisplay-end-trigger-functions and related defunsStefan Kangas2022-07-311-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | This variable and related functions have been obsolete since 23.1. The last things to depend on this (fast-lock.el and lazy-lock.el) were recently removed. * src/dispextern.h (struct it): Delete field 'redisplay_end_trigger_charpos'. * src/window.c (Fwindow_redisplay_end_trigger) (Fset_window_redisplay_end_trigger): Delete defuns and corresponding defsubrs for functions obsolete since 23.1. * src/window.h (wset_redisplay_end_trigger): Delete function. (GCALIGNED_STRUCT): Delete 'redisplay_end_trigger'. * src/xdisp.c (run_redisplay_end_trigger_hook): Delete function. (syms_of_xdisp) <redisplay_end_trigger_functions>: Delete variable obsolete since 23.1. (init_iterator, next_element_from_buffer): Don't run or set above deleted hook variable. * lisp/subr.el: Delete obsoletion definitions for above deleted defuns and variable. * doc/lispref/hooks.texi (Standard Hooks): * lisp/emacs-lisp/byte-opt.el (side-effect-free-fns): * lisp/loadhist.el (unload-feature-special-hooks): Don't mention above deleted variable. * admin/coccinelle/window.cocci: Adjust for above changes.
* Fix native compiler handling of narrow-to-regionGerd Möllmann2022-07-301-5/+1
| | | | | * lisp/emacs-lisp/comp.el (comp-limplify-lap-inst): Use auto for byte-narrow-to-region.
* Tweak icons.el emoji detectionLars Ingebrigtsen2022-07-301-1/+1
| | | | | | * lisp/emacs-lisp/icons.el (icons--create): Choose another character that's unlikely to appear in non-Emoji fonts. (Comment left in place since this should be fixed in a less breakable way.)
* ; * lisp/emacs-lisp/icons.el (icon-preference): repair typeMattias Engdegård2022-07-301-4/+4
|
* Handle the optional argument of 'narrow-to-region' in byte-compiled code.Gregory Heytings2022-07-301-2/+2
| | | | | | * lisp/emacs-lisp/bytecomp.el: Adapt the specifications. * src/bytecode.c (exec_byte_code): Get the optional argument.
* ; * lisp/emacs-lisp/regi.el: Delete incorrect "last modified" comment.Stefan Kangas2022-07-301-1/+0
|
* Adapt native compiler to change in narrow-to-regionGerd Möllmann2022-07-291-1/+2
| | | | | * lisp/emacs-lisp/comp.el (comp-limplify-lap-inst): Add third argument nil for narrow-to-region.
* Cleanup `string-equal-ignore-case' declarations.Sam Steingold2022-07-281-4/+3
| | | | | | | | | | | | | | Also, a minor declaration cleanup for other `compare-strings' thin wrappers. * lisp/emacs-lisp/byte-opt.el (side-effect-free-fns): Remove `string-equal-ignore-case', `string-prefix-p', `string-suffix-p'. (side-effect-and-error-free-fns): Add `proper-list-p' (it already was in `pure-fns'). (pure-fns): Remove `string-prefix-p', `string-suffix-p' (`string-equal-ignore-case' was missing here). * lisp/subr.el (proper-list-p): Remove partially duplicate `put's from here. (string-equal-ignore-case, string-prefix-p, string-suffix-p): Add `pure' and `side-effect-free' declarations. (string-equal-ignore-case): Make inline.
* Comment fixes for recent icon codeLars Ingebrigtsen2022-07-281-2/+0
| | | | | | * lisp/cus-edit.el (custom-icon-state): Add comment. * lisp/emacs-lisp/icons.el: Remove comment.
* ; Minor fixes to the "icons" featureEli Zaretskii2022-07-281-1/+3
| | | | | | | | * lisp/emacs-lisp/icons.el (icons--create): Use 'display-images-p' to test for image capability. * doc/lispref/display.texi (Icons): Improve indexing, cross-references, and wording.
* ; Delete LCD Archive entriesStefan Kangas2022-07-282-14/+2
| | | | | | | * lisp/emacs-lisp/advice.el: * lisp/emacs-lisp/trace.el: * lisp/mail/feedmail.el: * lisp/mail/supercite.el: Delete entries for the defunct LCD Archive.
* Use icons in warnings buffersLars Ingebrigtsen2022-07-281-25/+30
| | | | | | | | * lisp/emacs-lisp/warnings.el (warning-suppress-action) (warning-suppress-log-action): Removed. New icon. (warnings-suppress): New helper function. (display-warning): Use it (bug#46025).
* Add support for user-customizable iconsLars Ingebrigtsen2022-07-281-0/+265
| | | | | | | | | | | | | | | | | | | | | | | | | | | | * doc/emacs/custom.texi (Specific Customization): Mention it. * doc/emacs/display.texi (Icons): New node. * doc/lispref/display.texi (Icons): New node. * lisp/button.el (buttonize): (button--properties, buttonize-region): Allow not overriding faces. * lisp/cus-edit.el (custom-save-all): Save icons. (custom-icon): New widget. (custom-icon-value-create, custom-toggle-hide-icon) (custom--icons-widget-value, custom-icon-set): Helper functions for the widget. (customize-icon): Main command. (custom-icon-state-set, custom-icon-state): Helper functions. (custom-theme-set-icons): Function to be used by theme writers. (custom-set-icons): Function to be used in .emacs. (custom-save-icons): New function. * lisp/custom.el (custom-push-theme): Add icons. * lisp/emacs-lisp/icons.el: New file. * test/lisp/emacs-lisp/icons-tests.el: Add some tests.
* string-equal-ignore-case: new functionSam Steingold2022-07-264-8/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * lisp/cedet/semantic/complete.el (semantic-collector-calculate-completions): Use `string-prefix-p' instead of explicit `compare-strings'. * lisp/emacs-lisp/byte-opt.el (side-effect-free-fns): Add `string-equal-ignore-case'. * lisp/emacs-lisp/cl-extra.el (cl-equalp): Use `string-equal-ignore-case'. * lisp/emacs-lisp/shadow.el (load-path-shadows-find): Likewise. * lisp/emacs-lisp/shortdoc.el (string): Add `string-equal-ignore-case'. * lisp/files.el (file-truename): Use `string-equal-ignore-case'. (file-relative-name): Likewise. * lisp/gnus/gnus-art.el (article-hide-boring-headers): Use `string-equal-ignore-case' instead of `gnus-string-equal'. * lisp/gnus/gnus-util.el (gnus-string-equal): Remove, use `string-equal-ignore-case' instead. * lisp/international/mule-cmds.el (describe-language-environment): Use `string-equal-ignore-case'. (locale-charset-match-p): Likewise. * lisp/man.el (Man-softhyphen-to-minus): Use `string-prefix-p'. * lisp/minibuffer.el (completion--string-equal-p): Remove, use `string-equal-ignore-case' instead. (completion--twq-all): Use `string-equal-ignore-case'. (completion--do-completion): Likewise. * lisp/net/browse-url.el (browse-url-default-windows-browser): Use `string-prefix-p' instead of explicit `compare-strings'. * lisp/org/ob-core.el (org-babel-results-keyword): Use `string-equal-ignore-case' instead of explicit `compare-strings'. (org-babel-insert-result): Likewise. * lisp/org/org-compat.el (string-equal-ignore-case): Define unless defined already. (org-mode-flyspell-verify): Use `string-equal-ignore-case'. * lisp/org/org-lint.el (org-lint-duplicate-custom-id): Likewise. * lisp/org/ox.el (org-export-resolve-radio-link): Use `string-equal-ignore-case' and `string-clean-whitespace'. * lisp/progmodes/flymake-proc.el (flymake-proc--check-patch-master-file-buffer): Use `string-prefix-p' instead of explicit `compare-strings'. * lisp/progmodes/idlwave.el (idlwave-class-or-superclass-with-tag): Use `string-equal-ignore-case' instead of explicit `compare-strings'. * lisp/subr.el (member-ignore-case): Use `string-equal-ignore-case'. (string-equal-ignore-case): Compare strings ignoring case. * lisp/textmodes/bibtex.el (bibtex-string=): Remove. (bibtex-format-entry, bibtex-font-lock-url, bibtex-autofill-entry) (bibtex-print-help-message, bibtex-validate, bibtex-validate-globally) (bibtex-clean-entry, bibtex-completion-at-point-function, (bibtex-url): Use `string-equal-ignore-case' instead of `bibtex-string='. * lisp/textmodes/sgml-mode.el (sgml-get-context): Use `string-equal-ignore-case' instead of explicit `compare-strings'. (sgml-calculate-indent): Likewise * test/lisp/subr-tests.el (string-comparison-test): Add tests for `string-equal-ignore-case'.
* Make package-archives URL treatment slighty laxerRobert Pluim2022-07-251-1/+1
| | | | | | | | 'package-archives' URLs are expected to end in '/', but we can cater for people typoing that by using 'url-expand-file-name'. * lisp/emacs-lisp/package.el (package--with-response-buffer-1): Use 'url-expand-file-name' instead of 'concat'.
* Don't exclude current dir in `package--reload-previously-loaded'Paul Pogonyshev2022-07-241-6/+21
| | | | | * lisp/emacs-lisp/package.el (package--reload-previously-loaded): Don't exclude the current directory (bug#56614).