summaryrefslogtreecommitdiff
path: root/lisp/emacs-lisp
Commit message (Collapse)AuthorAgeFilesLines
* (byte-compile--first-symbol-with-pos): Fix bug#58601Stefan Monnier2022-10-181-21/+17
| | | | | * lisp/emacs-lisp/bytecomp.el: Require `subr-x`. (byte-compile--first-symbol-with-pos): Avoid inf-loops on circular data.
* Fix previous loaddefs-gen fixLars Ingebrigtsen2022-10-181-3/+2
|
* Fix faulty loaddefs detectionLars Ingebrigtsen2022-10-181-1/+2
| | | | | * lisp/emacs-lisp/loaddefs-gen.el (loaddefs-generate--emacs-batch): Fix faulty loaddefs detection.
* * Prevent potential native compilation infinite recursionsAndrea Corallo2022-10-181-83/+85
| | | | | | * lisp/emacs-lisp/comp.el (comp-no-spawn): New var. (comp-subr-trampoline-install, comp-final, comp-run-async-workers) (comp--native-compile): Update.
* Improve native-compile-prune-cache messagesStefan Kangas2022-10-171-1/+1
| | | | | * lisp/emacs-lisp/comp.el (native-compile-prune-cache): Quote name of pruned directory.
* Don't prune *.eln files in parent of eln-load-pathStefan Kangas2022-10-171-1/+3
| | | | | | | | * lisp/emacs-lisp/comp.el (native-compile-prune-cache): Don't prune *.eln files in parent directory of `native-comp-eln-load-path'. * test/lisp/emacs-lisp/comp-tests.el (test-native-compile-prune-cache/dont-delete-in-parent-of-cache): New test.
* Fix spurious "Compilation finished" native-comp messagesLars Ingebrigtsen2022-10-171-3/+8
| | | | | | | | * lisp/emacs-lisp/comp.el (native--compile-async): Don't start the async compilation if we didn't add anything. This avoids spurious "Compilation finished" messages in the *Async* buffer when it turned out that all the files we considered nativecomping were skipped.
* Avoid having the async compile log saying it's compiling loaddefsLars Ingebrigtsen2022-10-172-3/+10
| | | | | | | | | | | | | * lisp/loadup.el (featurep): Define the hash table in nativecomp builds (but not otherwise). A more natural place to define this would be in comp.el, but comp.el isn't loaded yet when we load the .elc file that updates comp--no-native-compile. We could change the load order and move the definition to comp.el, though. * lisp/emacs-lisp/bytecomp.el (byte-compile-from-buffer): Allow inhibiting nativecomp earlier (bug#57627). * lisp/emacs-lisp/comp.el (native-compile-async-skip-p): Use the data.
* cl-generic: Fix `advertised-calling-convention` declarationsStefan Monnier2022-10-163-6/+15
| | | | | | | | | | | | | | | * lisp/emacs-lisp/cl-generic.el (cl-generic-define-method): Preserve the `advertised-calling-convention`, if any (bug#58563). * lisp/subr.el (declare): Warn when we hit this. * lisp/emacs-lisp/byte-run.el (get-advertised-calling-convention): New fun. * lisp/progmodes/elisp-mode.el (elisp-get-fnsym-args-string): * lisp/help-fns.el (help-fns--signature): * lisp/emacs-lisp/bytecomp.el (byte-compile-fdefinition): Use it. * test/lisp/emacs-lisp/cl-generic-tests.el (cl-generic-tests--acc): New fun. (cl-generic-tests--advertised-calling-convention-bug58563): New test.
* Handle ;;;###theme-autoload comments in etc/themesPhilip Kaludercic2022-10-151-1/+8
| | | | | | * lisp/emacs-lisp/loaddefs-gen.el (loaddefs-generate--emacs-batch): Extract the autoloads and have them loaded along with loaddefs.el. * etc/NEWS: Mention the new feature. (Bug#57639)
* Tag themes with propertiesPhilip Kaludercic2022-10-151-0/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * doc/emacs/custom.texi (Custom Themes): Document 'theme-choose-variant'. * doc/lispref/customize.texi (Custom Themes): Document the new optional argument to 'deftheme'. (Autoload): Mention that 'deftheme' is not copied verbatim. * etc/themes/adwaita-theme.el (adwaita): Add properties. * etc/themes/deeper-blue-theme.el (deeper-blue): Add properties. * etc/themes/dichromacy-theme.el (dichromacy): Add properties. * etc/themes/light-blue-theme.el (light-blue): Add properties. * etc/themes/manoj-dark-theme.el (manoj-dark): Add properties. * etc/themes/misterioso-theme.el (misterioso): Add properties. * etc/themes/tango-dark-theme.el (tango-dark): Add properties. * etc/themes/tango-theme.el (tango): Add properties. * etc/themes/tsdh-dark-theme.el (tsdh-dark): Add properties. * etc/themes/tsdh-light-theme.el (tsdh-light): Add properties. * etc/themes/wheatgrass-theme.el (wheatgrass): Add properties. * etc/themes/whiteboard-theme.el (whiteboard): Add properties. * etc/themes/wombat-theme.el (wombat): Add properties. * etc/themes/modus-operandi-theme.el: Add properties. * etc/themes/modus-vivendi-theme.el: Add properties. * etc/themes/leuven-dark-theme.el (leuven-dark): Add properties. * etc/themes/leuven-theme.el (leuven): Add properties. * lisp/custom.el (deftheme): Allow for optional arguments to set the property list. (custom-declare-theme): Accept the same optional arguments as 'deftheme'. (theme-list-variants): Add new function. (theme-choose-variant): Add new command for switching between members of a theme family. (toggle-theme): Add an alias for 'theme-choose-variant'. * lisp/emacs-lisp/loaddefs-gen.el (loaddefs-generate--make-autoload): Handle 'defcustom's by extracting the properties. (Bug#57639)
* Use file-size-human-readable in memory-report--formatStefan Kangas2022-10-151-6/+1
| | | | | * lisp/emacs-lisp/memory-report.el (memory-report--format): Use file-size-human-readable.
* Add trampoline AOT compilation target (bug#58318)Andrea Corallo2022-10-111-0/+11
| | | | | | | * Makefile.in (trampolines): New target. * lisp/Makefile.in (trampolines): Likewise. * lisp/emacs-lisp/comp.el (comp-compile-all-trampolines): New function.
* package.el: Understand a few more variations in tarball formatsStefan Monnier2022-10-081-3/+7
| | | | | | | | | | * lisp/emacs-lisp/package.el (package-untar-buffer): Fix thinko. (package-tar-file-info): Handle the case where the first file is in a subdirectory. * test/lisp/emacs-lisp/package-tests.el (package-test-bug58367): New test. * test/lisp/emacs-lisp/package-resources/ustar-withsub-0.1.tar: * test/lisp/emacs-lisp/package-resources/v7-withsub-0.1.tar: New files.
* Fix vtable-insert-object line insertionLars Ingebrigtsen2022-10-081-3/+11
| | | | | | * lisp/emacs-lisp/vtable.el (vtable-insert-object): Pass in the correct ellipsis values (bug#58370). (vtable--insert-line): Don't bug out on missing optional arguments.
* Mention seq-keep in shortdocLars Ingebrigtsen2022-10-081-0/+2
| | | | * lisp/emacs-lisp/shortdoc.el (sequence): Mention seq-keep.
* ; Silence byte-compiler in benchmark.elStefan Kangas2022-10-071-0/+1
| | | | * lisp/emacs-lisp/benchmark.el (cl-lib): Require.
* Clearer byte-compiler arity warnings (bug#58319)Mattias Engdegård2022-10-071-1/+3
| | | | | * lisp/emacs-lisp/bytecomp.el (byte-compile-arglist-signature-string): Replace '3+' and '3-4' with '3 or more' and '3 or 4', respectively.
* Improve package-check-signature docstringStefan Kangas2022-10-071-10/+17
| | | | | * lisp/emacs-lisp/package.el (package-check-signature): Improve docstring.
* Fix calling `package-reinstall' just after quick initialization.Matt Armstrong2022-10-061-4/+8
| | | | | | | | * lisp/emacs-lisp/package.el (package-reinstall): call `package--archives-initialize', just like `package-install' does. This populates `package-alist', and so fixes calling `package-reinstall' as the first thing done after package "quick init" (Bug#53527).
* Add 'seq-keep'Lars Ingebrigtsen2022-10-041-0/+4
| | | | | * doc/lispref/sequences.texi (Sequence Functions): Document it. * lisp/emacs-lisp/seq.el (seq-keep): New function (bug#58278).
* Make `eq' obsolete as a generalized variableLars Ingebrigtsen2022-10-041-0/+1
| | | | | * lisp/emacs-lisp/gv.el (eq): Make obsolete as a generalized variable.
* Make loaddefs-generate more resilientLars Ingebrigtsen2022-10-041-1/+1
| | | | | | * lisp/emacs-lisp/loaddefs-gen.el (loaddefs-generate): Don't bug out when there's an existing loaddefs file that's not formatted properly (bug#58280).
* Don't bug out in advice--make-docstring when there's not doc stringLars Ingebrigtsen2022-10-041-1/+2
| | | | | * lisp/emacs-lisp/nadvice.el (advice--make-docstring): Don't bug out on functions with no documentation (bug#58284).
* ; Fix logic of $HOME adjustment for 'ert-remote-temporary-file-directory'Jim Porter2022-10-031-1/+1
| | | | | * lisp/emacs-lisp/ert-x.el (ert-remote-temporary-file-directory): Only adjust $HOME when it doesn't exist (bug#58265).
* Rename to inhibit-automatic-native-compilationLars Ingebrigtsen2022-10-031-1/+1
| | | | | | | | | | | | | * src/comp.c (maybe_defer_native_compilation): (syms_of_comp): * lisp/subr.el (native-comp-deferred-compilation): * lisp/startup.el (inhibit-native-compilation): (normal-top-level): * lisp/progmodes/elisp-mode.el (emacs-lisp-native-compile-and-load): * lisp/emacs-lisp/comp.el (comp-trampoline-compile): * etc/NEWS: * doc/lispref/compile.texi (Native-Compilation Variables): Rename inhibit-native-compilation to inhibit-automatic-native-compilation.
* Add new variable 'inhibit-native-compilation'Lars Ingebrigtsen2022-10-031-16/+20
| | | | | | | | | | | | | | | | | | | | * doc/lispref/compile.texi (Native-Compilation Variables): Document it. * lisp/startup.el (normal-top-level): Set inhibit-native-compilation from environment variable. * lisp/subr.el (native-comp-deferred-compilation): Make obsolete. * lisp/emacs-lisp/comp.el (comp-trampoline-compile): Don't write trampolines to disk. * lisp/progmodes/elisp-mode.el (emacs-lisp-native-compile-and-load): Adjust. * src/comp.c (syms_of_comp): New variable inhibit-native-compilation. (maybe_defer_native_compilation): Use it.
* Fix more overly long docstrings in eieioStefan Kangas2022-10-031-8/+11
| | | | | * lisp/emacs-lisp/eieio.el (defclass): Fix more overly long docstrings. (Bug#58252)
* Fix overly wide docstrings generated by eieioStefan Kangas2022-10-021-6/+12
| | | | | | * lisp/emacs-lisp/eieio-core.el (eieio-make-class-predicate) (eieio-make-child-predicate, eieio-defclass-internal): Don't generate overly wide docstrings. (Bug#58252)
* ; Fix typos (prefer American spelling)Stefan Kangas2022-09-291-2/+2
|
* package-update would always re-install packageLin Sun2022-09-281-2/+2
| | | | | | * lisp/emacs-lisp/package.el (package--updateable-packages): fix version comparison between available packages and archived packages (bug#58129).
* ert-x: Improve realism of `ert-with-test-buffer-selected'Richard Hansen2022-09-271-1/+9
| | | | | | * lisp/emacs-lisp/ert-x.el (ert-with-test-buffer-selected): Set `inhibit-read-only' and `buffer-read-only' to nil when executing the body to provide a more realistic test environment.
* Fix percentage width computation in vtableLars Ingebrigtsen2022-09-261-1/+2
| | | | | * lisp/emacs-lisp/vtable.el (vtable--compute-width): Fix percentage computation (bug#58067).
* ; Clarify wording of some doc strings in shortdoc.elEli Zaretskii2022-09-251-4/+4
| | | | | | * lisp/emacs-lisp/shortdoc.el (shortdoc-next, shortdoc-previous) (shortdoc-next-section, shortdoc-previous-section): Clarify wording.
* Boolean constant detection additionsMattias Engdegård2022-09-251-1/+2
| | | | | | * lisp/emacs-lisp/byte-opt.el (byte-opt--bool-value-form): `set` is boolean identity in its second argument. (byte-compile-trueconstp): `set-marker` is always true.
* Add :buffer argument to ert-with-temp-fileStefan Kangas2022-09-251-2/+16
| | | | | | * lisp/emacs-lisp/ert-x.el (ert-with-temp-file): Add new keyword argument :buffer SYMBOL to visit the file with `find-file-literally' before running the body, and cleaning up after.
* Improve shortdoc documentationStefan Kangas2022-09-251-8/+17
| | | | | | | | | * doc/emacs/help.texi (Name Help): * doc/lispref/help.texi (Documentation Groups): Refer to 'shortdoc' convenience alias instead of 'shortdoc-display-group'. * lisp/emacs-lisp/shortdoc.el: Add Commentary. (shortdoc-next, shortdoc-previous) (shortdoc-next-section, shortdoc-previous-section): Doc fixes.
* Fix shortdoc movement commandsStefan Kangas2022-09-251-1/+1
| | | | | * lisp/emacs-lisp/shortdoc.el (shortdoc--goto-section): Don't skip over current function or section when searching.
* Add new command 'shortdoc-copy-function-as-kill'Stefan Kangas2022-09-251-1/+16
| | | | | | * lisp/emacs-lisp/shortdoc.el (shortdoc-copy-function-as-kill): New command. (shortdoc-mode-map): Bind above new command to "w".
* Bind "N"/"P" to next/prev section in shortdocStefan Kangas2022-09-251-0/+2
| | | | | * lisp/emacs-lisp/shortdoc.el (shortdoc-mode-map): Bind "N" and "P" to 'shortdoc-next-section' and 'shortdoc-previous-section'.
* * lisp/emacs-lisp/icons.el (icons--create): Use default rotation 0 (bug#57813)Juri Linkov2022-09-241-1/+1
|
* Remove "manual" package--builtin-versions updatesLars Ingebrigtsen2022-09-242-10/+1
| | | | | | | * lisp/emacs-lisp/nadvice.el: * lisp/emacs-lisp/cl-generic.el: Don't push to package--builtin-versions "manually", because loaddefs-gen does this correctly now.
* Tweak how :override advice is formatted in *Help*Lars Ingebrigtsen2022-09-241-12/+28
| | | | | | * lisp/emacs-lisp/nadvice.el (advice--make-single-doc): Format :overrides specially (bug#57974). (advice--make-docstring): Put overrides at the front.
* Rename file-name-directoryLars Ingebrigtsen2022-09-241-5/+5
| | | | | | | * lisp/emacs-lisp/shortdoc.el (file-name): * doc/lispref/files.texi (Directory Names): Adjust. * lisp/files.el (file-name-parent-directory): Rename from `file-name-directory' (bug#58039).
* * lisp/emacs-lisp/shortdoc.el (file-name): Improve examples.Stefan Kangas2022-09-241-4/+2
|
* * lisp/emacs-lisp/eieio.el (defclass): Fix bug#51068Stefan Monnier2022-09-231-0/+1
| | | | | Accept (defclass <class> <superclasses> (.. <slotname> ..)) without having to wrap the slot name within parentheses.
* cconv.el: Fix interactive closure bug#51695Stefan Monnier2022-09-232-15/+51
| | | | | | | | | | | | | | | | | | | | Make cconv.el detect when a closure's interactive form needs to capture variables from the context and tweak the code accordingly if so. * lisp/emacs-lisp/cconv.el (cconv--interactive-form-funs): New var. (cconv-convert): Handle the case where the interactive form captures vars from the surrounding context. Remove left over handling of `declare` which was already removed from the cconv-analyze` phase. (cconv-analyze-form): Adjust analysis of interactive forms accordingly. * lisp/emacs-lisp/oclosure.el (cconv--interactive-helper): New type and function. * lisp/simple.el (function-documentation, oclosure-interactive-form): Add methods for it. * test/lisp/emacs-lisp/cconv-tests.el (cconv-tests-interactive-closure-bug51695): New test.
* Make loaddefs-gen register parent :groups from defcustomLars Ingebrigtsen2022-09-231-2/+6
| | | | | | * lisp/emacs-lisp/loaddefs-gen.el (loaddefs-generate--make-autoload): Also register parent :groups from `defgroup' entries (bug#58015).
* Don't rewrite `set` to `setq` of lexical variablesMattias Engdegård2022-09-221-9/+10
| | | | | | | | | | | | | | | Only perform the rewrite (set 'VAR X) -> (setq VAR X) for dynamic variables, as `set` isn't supposed to affect lexical vars (and never does so when interpreted). * lisp/emacs-lisp/byte-opt.el (byte-optimize-set): * test/lisp/emacs-lisp/bytecomp-tests.el (bytecomp-tests--xx): New. (bytecomp-tests--test-cases): Add test cases. * test/lisp/emacs-lisp/bytecomp-resources/warn-variable-set-nonvariable.el: Remove obsolete test.
* ; * lisp/emacs-lisp/gv.el (gv-synthetic-place): Doc fix.Eli Zaretskii2022-09-211-2/+4
|