Make tty-run-terminal-initialization load the .elc file (if any)

* lisp/faces.el (tty-run-terminal-initialization):
`locate-library' may have found the .el.gz file (bug#51116).
This commit is contained in:
Lars Ingebrigtsen 2021-10-11 11:22:05 +02:00
parent 07edc28bdb
commit e9df86004f

View file

@ -2289,7 +2289,9 @@ If you set `term-file-prefix' to nil, this function does nothing."
(let ((file (locate-library (concat term-file-prefix type))))
(and file
(or (assoc file load-history)
(load (file-name-sans-extension file)
(load (replace-regexp-in-string
"\\.el\\(\\.gz\\)?\\'" ""
file)
t t)))))
type)
;; Next, try to find a matching initialization function, and call it.