help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

defalias inside a defun


From: Heime
Subject: defalias inside a defun
Date: Sat, 06 Apr 2024 00:59:40 +0000

Would it be acceptable to call a defalias inside a defun ?\

I have the function avus and want to make a few alias functions 
when requiring a specific file.  For instance including gala-bash-func
as an alternative to avus-bash-func defined in avus-bash.el

(defun gala ()
  "Require libraries based on major mode."
  (interactive)

  (cond

    ((eq major-mode 'sh-mode)
          (require 'avus-bash)
          (defalias 'gala-bash-func #'avus-bash-func))))





reply via email to

[Prev in Thread] Current Thread [Next in Thread]