(file-name-base output) "-")
nil ".el")))
(with-temp-file temp-file
+ (insert ";; -*-coding: nil; -*-\n")
(insert (prin1-to-string expr)))
(with-temp-buffer
(unwind-protect
--- /dev/null
+;;; -*- lexical-binding: t; -*-
+
+;; Reduced from ivy.el.
+
+(defvar comp-test-45603-last)
+(defvar comp-test-45603-mark-prefix)
+(defvar comp-test-45603-directory)
+(defvar comp-test-45603-marked-candidates)
+
+(defun comp-test-45603--call-marked (action)
+ (let* ((prefix-len (length comp-test-45603-mark-prefix))
+ (marked-candidates
+ (mapcar
+ (lambda (s)
+ (let ((cand (substring s prefix-len)))
+ (if comp-test-45603-directory
+ (expand-file-name cand comp-test-45603-directory)
+ cand)))
+ comp-test-45603-marked-candidates))
+ (multi-action (comp-test-45603--get-multi-action comp-test-45603-last)))))
+
+(defalias 'comp-test-45603--file-local-name
+ (if (fboundp 'file-local-name)
+ #'file-local-name
+ (lambda (file)
+ (or (file-remote-p file 'localname) file))))
+
+(provide 'comp-test-45603)
(should (string= (comp-test-45635-f :height 180 :family "PragmataPro Liga")
"PragmataPro Liga")))
+(comp-deftest 45603-1 ()
+ "<https://lists.gnu.org/archive/html/bug-gnu-emacs/2020-12/msg01994.html>"
+ (load (native-compile (concat comp-test-directory "comp-test-45603.el")))
+ (should (fboundp #'comp-test-45603--file-local-name)))
+
\f
;;;;;;;;;;;;;;;;;;;;;
;; Tromey's tests. ;;