forked from colonelpanic/dotfiles
Use named-builder to build prefix-alternatives
This commit is contained in:
parent
a67eaab1d1
commit
ebbf363baa
@ -499,7 +499,7 @@ Prefix alternatives is a macro that builds an interactive function
|
|||||||
that selects one of a collection of functions that are provided to the
|
that selects one of a collection of functions that are provided to the
|
||||||
macro based on the value of the prefix argument.
|
macro based on the value of the prefix argument.
|
||||||
#+BEGIN_SRC emacs-lisp
|
#+BEGIN_SRC emacs-lisp
|
||||||
(defmacro imalison:prefix-alternatives-lambda (&rest alternatives)
|
(defmacro imalison:prefix-alternatives-fn (&rest alternatives)
|
||||||
`(lambda (arg)
|
`(lambda (arg)
|
||||||
(interactive "p")
|
(interactive "p")
|
||||||
(let ((function
|
(let ((function
|
||||||
@ -513,8 +513,7 @@ macro based on the value of the prefix argument.
|
|||||||
(setq current-prefix-arg nil)
|
(setq current-prefix-arg nil)
|
||||||
(call-interactively function))))
|
(call-interactively function))))
|
||||||
|
|
||||||
(imalison:named-builder-builder imalison:prefix-alternatives
|
(imalison:named-builder imalison:prefix-alternatives)
|
||||||
imalison:prefix-alternatives-lambda)
|
|
||||||
#+END_SRC
|
#+END_SRC
|
||||||
*** Use Package Wrapper With Local Load Path Support
|
*** Use Package Wrapper With Local Load Path Support
|
||||||
#+BEGIN_SRC emacs-lisp
|
#+BEGIN_SRC emacs-lisp
|
||||||
|
Loading…
Reference in New Issue
Block a user