Commit Graph

9 Commits

Author SHA1 Message Date
Stephan Creutz
7bc810803d Use cl-mapcan instead of mapcan
The function mapcan exists outside cl since Emacs 26.1.
2021-06-13 16:03:08 +02:00
Stephan Creutz
ccca97f226 Replace cl by cl-lib
Since Emacs 27 the package cl is deprecated, the replacement is
cl-lib, which is available since Emacs 24.3.

This patch replaces cl by cl-lib and drops support for Emacs versions
less than 24.3. Dropping older Emacsen is required, because cl-lib is
a builtin starting from version 24.3 and doesn't need an extra package
from ELPA.

Testcases for past issues still contain cl. Most of them seem to be
broken and need further investigation.

This patch is tested with test/run-ert.sh, which outputs:

Ran 10 tests, 10 results as expected, 0 unexpected (2021-01-30 13:24:54+0100, 0.672122 sec)
1 expected failures

and manually by daily usage for a month now.
2021-06-13 16:03:08 +02:00
Stephan Creutz
5f26b07ae3 Unbreak el-get-remove-autoloads for Emacs < 28
Starting from Emacs 28 the function autoload-file-load-name takes two
non-optional parameters, but versions before Emacs 27 still takes only
one.
2021-06-11 21:05:38 +02:00
Vedang Manerikar
cb66b4a88f Pass the loaddefs file to the autoload-file-load-name function
This is a compulsory argument and was missing from the code at the
moment (testing against Emacs 28.0.50)
2021-02-14 14:03:52 +05:30
Noam Postavsky
4dc7804bb2 el-get-remove-autoloads: cleanup .loaddefs buffer
Save it if needed, and close it if we opened it ourselves.
2016-04-13 21:45:51 -04:00
Noam Postavsky
f5faf0b802 Don't add .loaddefs to the recentf list
* el-get-autoloading.el (el-get-remove-autoloads):
(el-get-update-autoloads): let-bind `recentf-exclude' to avoid adding
.loaddefs to the recentf list.
2016-04-13 21:43:12 -04:00
Noam Postavsky
5339d60596 let-bind ff-visit-truename for autoload update
* el-get-autoloading.el (el-get-update-autoloads): Let-bind
  find-file-visit-truename to nil.
2015-03-27 16:32:59 -04:00
Noam Postavsky
1ee5da9fb6 kill .loaddefs if visited via non-standard path
update-directory-autoloads ends up thinking it is a "secondary" autoload
file, so it puts MD5 checksums instead of timestamps.

* el-get-autoloading.el (el-get-update-autoloads): use
  find-buffer-visiting instead of get-file-buffer to detect buffers
  visiting .loaddefs via non-standard path, and call kill-buffer if we
  find such buffers.
2015-03-27 16:32:58 -04:00
Noam Postavsky
c9816843de rename el-get-autoload{s, => ing}
package.el uses <pkg-name>-autoloads.el as the destination for autoloads
generated from cookies. Meaning that during a MELPA bootstrap install
these get appended to el-get-autoloads.el. Although it's currently
harmless during bootstrap, better to avoid any possible future problems.
2014-11-29 15:05:06 -05:00