[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#17348: 24.3.50; Cannot advice-add the same function :before and :aft
From: |
Stefan Monnier |
Subject: |
bug#17348: 24.3.50; Cannot advice-add the same function :before and :after |
Date: |
Sat, 10 May 2014 16:09:21 -0400 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/24.4.50 (gnu/linux) |
I installed a patch in `emacs-24' which will let you add the same
function multiple times, as long as you specify different `name'
properties for each one.
>> In the actual situation that lead me to adding the same function twice,
>> it was a tracing function, like (message "time: %s ; value of
>> foovariable: %s" (current-time) foovariable) and I assumed that I would
>> be able to remove them both with one (advice-remove ...) -- I guess that
>> isn't too complicated.
> Removing them both would not be desirable in general.
With the new code, you can remove each one individually by specifying
its `name', or you can remove them all by specifying the function itself.
Stefan