[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Redefining functions and variables
From: |
Tim X |
Subject: |
Re: Redefining functions and variables |
Date: |
Wed, 08 Dec 2010 15:21:57 -0000 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/23.1 (gnu/linux) |
Johan Bockgård <bojohan+news@gnu.org> writes:
> Elena <egarrulo@gmail.com> writes:
>
>>> (defmacro defun (name args &rest body)
>>> `(progn
>>> (message "defining %S" name)
>>> (,old-defun ,name ,args ,@body)))
>>
>> This is very close to what I was looking for.
>
> Note that neither defadvice nor redefinition of defun will work for
> (already) byte compiled code.
>
>
> (byte-compile (lambda () (defun foo ()))) =>
>
> #[nil "..." [defalias foo #[nil "..." [nil] 1]] 3]
> ^
> no `defun' after byte compilation
Not sure what you mean here, but I have lots of defadvice that is
defined for functions that are already defined and byte compiled which
work fine i.e. I use defadvice to advise standard emacs lisp functions
regularly without problems.
Tim
--
tcross (at) rapttech dot com dot au
- Re: Redefining functions and variables, (continued)
- Re: Redefining functions and variables, Stefan Monnier, 2010/12/08
- Re: Redefining functions and variables, Uday S Reddy, 2010/12/08
- Re: Redefining functions and variables, Andreas Politz, 2010/12/08
- Re: Redefining functions and variables, Johan Bockgård, 2010/12/08
- Re: Redefining functions and variables, Andreas Politz, 2010/12/08
- Re: Redefining functions and variables, Tim X, 2010/12/08
- Re: Redefining functions and variables, Pascal J. Bourguignon, 2010/12/08
- Re: Redefining functions and variables, Elena, 2010/12/08
- Re: Redefining functions and variables, Pascal J. Bourguignon, 2010/12/08
- Re: Redefining functions and variables, Johan Bockgård, 2010/12/08
- Re: Redefining functions and variables,
Tim X <=