diff options
author | Andrea Corallo <akrl@sdf.org> | 2021-04-25 20:06:22 +0200 |
---|---|---|
committer | Andrea Corallo <akrl@sdf.org> | 2021-04-25 20:06:22 +0200 |
commit | 289000eee729689b0cf362a21baa40ac7f9506f6 (patch) | |
tree | 04e59d0f2bd7111749d8d97f829a410d4602a247 /test/src/comp-test-45603.el | |
parent | 8f63f0078a23421eada97b4da51b9308b82532ce (diff) | |
parent | fa65c044f2ebe666467166075c1507a8d0e1347f (diff) | |
download | emacs-289000eee729689b0cf362a21baa40ac7f9506f6.tar.gz |
Merge branch 'feature/native-comp' into into trunk
Diffstat (limited to 'test/src/comp-test-45603.el')
-rw-r--r-- | test/src/comp-test-45603.el | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/test/src/comp-test-45603.el b/test/src/comp-test-45603.el new file mode 100644 index 00000000000..f1c0dafb68d --- /dev/null +++ b/test/src/comp-test-45603.el @@ -0,0 +1,28 @@ +;;; -*- 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) |