本文介绍了Emacs Lisp中@字符的作用是什么?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

例如在这个宏定义中使用:

As used for instance in this macro definition:

(defmacro with-eval-after-load-feature (feature &rest body)
  (declare (indent 1) (debug t))
  (let* ((feature (if (and (listp feature) (eq (car-safe feature) 'quote))
                      (cdr feature) feature))
         (fs (if (listp feature) feature (list feature)))
         (form (or (and (eval '(eval-when (compile)
                                 (with-eval-after-load-feature-preload fs)))
                        'with-no-warnings)
                   'progn)))
    `(,form ,@(with-eval-after-load-feature-transform fs body))))

in 。

推荐答案

它用于在反引号的表达式中拼接。参见 C-h(elisp)Backquote RET 。例如:

It's used for splicing in backquoted expressions. See C-h i g (elisp) Backquote RET. For example:

elisp> `(1 2 ,(list 3 4))  ; no splicing => nested list
(1 2
   (3 4))

elisp> `(1 2 ,@(list 3 4)) ; splicing => flat list
(1 2 3 4)

这篇关于Emacs Lisp中@字符的作用是什么?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

10-20 02:49